|
|
1.1 root 1: #include "../scsi.h"
2:
3: void
4: pperror(char *buf, char *mesg)
5: {
6: extern int sys_nerr;
7: extern char *sys_errlist[];
8: extern int errno;
9:
10: if((errno < 0) || (errno >= sys_nerr))
11: sprintf(buf, "%s: unknown errno %d", mesg, errno);
12: else
13: sprintf(buf, "%s: %s", mesg, sys_errlist[errno]);
14: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.