PERROR

Section: Library functions (3)
Updated: March 16, 1995
Index Return to Main Contents
 

NAME

perror - print a system error message  

SYNOPSIS

#include <stdio.h>

void perror(const char *s);  

DESCRIPTION

perror produces a message on the standard error output, describing the last error encountered during a call to a system or library function. The argument string s is printed first, then a colon and a blank, then the message and a new-line. To be of most use, the argument string should include the name of the program that incurred the error. The error number is taken from the external variable errno, which is set when errors occur but not cleared when non-erroneous calls are made.  

CONFORMING TO

ANSI C, POSIX  

SEE ALSO

errno(2), strerror(3)


 

Index

NAME
SYNOPSIS
DESCRIPTION
CONFORMING TO
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 12:24:24 GMT, March 22, 2025