Loading...
Select Version
&pagelevel(3)&pagelevel
#include <netdb.h>
Kernighan-Ritchie-C:
char* gai_strerror(ecode);
int ecode;
ANSI-C:
char* gai_strerror(int ecode);
Description
The gai_strerror() function outputs an explanatory text string for an error code defined in <netdb.h>. The ecode parameter specifies an error code defined in <netdb.h>.
Return value
gai_strerror() returns a pointer to the string containing the explanatory text. If the value for ecode does not match any of the error codes for getaddrinfo() defined in <netdb.h>, the return value is a pointer to a string indicating an unknown error.