strerror_r

Name

strerror_r -- reentrant version of strerror

Synopsis

#include <string.h>

char *strerror_r(int errnum, char *buf, size_t buflen);

Description

strerror_r is a reentrant version of strerror. strerror_r returns a pointer to an error message corresponding to error number errnum. The returned pointer may point within the buffer buf (at most buflen bytes).

Note

Note the optional use of the buffer, unlike the strerror_r found in ISO POSIX (2003), in which the message is always copied into the supplied buffer. The return types also differ.