Return a string describing an errno.
String_Type errno_string (Integer_Type err)
The errno_string
function returns a string describing the
integer error code err
. The variable err
usually
corresponds to the errno
intrinsic function. See the
description for errno
for more information.
The errno_string
function may be used as follows:
define sizeof_file (file)
{
variable st = stat (file);
if (st == NULL)
verror ("%s: %s", file, errno_string (errno);
return st.st_size;
}
errno, stat, verror