XGetErrorText()XGetErrorText()NameXGetErrorText – obtain a description of error code.
Synopsis
XGetErrorText(display, code, buffer_return, length)
Display *display;
int code;
char *buffer_return;
int length;
Arguments
display Specifies a connection to an X server; returned from
XOpenDisplay().
code Specifies the error code for which you want to obtain a
description.
buffer_return
Returns the error description text. You allocate this memory.
length Specifies the size of the buffer.
DescriptionXGetErrorText() obtains textual descriptions of errors. XGetError‐
Text() copies a NULL-terminated string describing the specified error
code into the specified buffer with length length. The returned text
is in the encoding of the current locale. This string is copied from
static data and therefore may be freed. This routine allows extensions
to the Xlib library to define their own error codes and error strings
that can be accessed easily.
For more information, see Volume One, Chapter 3, Basic Window Program.
See AlsoXDisplayName(), XGetErrorDatabaseText(), XSetAfterFunction(), XSetEr‐
rorHandler(), XSetIOErrorHandler(), XSynchronize().
Xlib - Error Handling XGetErrorText()