std::strerror (3) - Linux Man Pages
Defined in header <cstring>
char* strerror( int errnum );
Returns a pointer to the textual description of the system error code errnum, identical to the description that would be printed by std::perror().
errnum is usually acquired from the errno variable, however the function accepts any value of type int. The contents of the string are locale-specific.
The returned string must not be modified by the program, but may be overwritten by a subsequent call to the strerror function. strerror is not required to be thread-safe. Implementations may be returning different pointers to static read-only string literals or may be returning the same pointer over and over, pointing at a static buffer in which strerror places the string.
errnum - integral value referring to a error code
Pointer to a null-terminated byte string corresponding to the errno error code errnum.
POSIX allows subsequent calls to strerror to invalidate the pointer value returned by an earlier call. It also specifies that it is the LC_MESSAGES locale facet that controls the contents of these messages.
// Run this code
E2BIG,_EACCES,_...,_EXDEV (macro constant)