mirror of
https://github.com/cahirwpz/libnix.git
synced 2025-12-08 14:58:56 +00:00
14 lines
256 B
C
14 lines
256 B
C
#include <stdio.h>
|
|
#include <string.h>
|
|
#include <errno.h>
|
|
|
|
void perror(const char *string)
|
|
{ int err=errno;
|
|
if(string!=NULL)
|
|
{ fputs(string,stderr);
|
|
fputc(':',stderr);
|
|
fputc(' ',stderr); }
|
|
fputs(strerror(err),stderr);
|
|
fputc('\n',stderr);
|
|
}
|