HP 3000 Manuals

perror [ HP C/iX Library Reference Manual ] MPE/iX 5.0 Documentation


HP C/iX Library Reference Manual

perror 

Prints an error message corresponding to errno.

Syntax 

     #include <stdio.h>
     void perror (const char *s);

Parameters 

s             A pointer to an optional string to be printed with the
              error message.  If a null pointer is passed, the parameter
              is ignored.

Return Values 

None.

Description 

The perror function prints an error message corresponding to the value of
errno.  First, if the argument s is not a null pointer or a pointer to a
null character, the string s is printed, followed by a colon and a blank,
then the message and a newline character are printed.

See Also 

errno, strerror(), ANSI C 4.9.10.4, POSIX.1 8.1



MPE/iX 5.0 Documentation