Sync NBSD libc errno.h with minix errno.h

This patch fixes some wrong error code number in nbsd libc's sys/errno.h
and adds new ones.

As in NetBSD the errno.h is used to automatically generate errlist.c array,
EBADCPU set to 1000 to be a bit too large, so we instruct the awk script
to stop at EDEADEPT (ELAST).
This commit is contained in:
Gianluca Guida
2011-03-04 22:37:43 +00:00
parent b87af1c325
commit 693842c855
2 changed files with 22 additions and 5 deletions

View File

@@ -73,11 +73,16 @@ BEGIN {
}
perror("ENOERROR", 0, "Undefined error: 0");
errno = 1;
last = 0;
}
/^#define/ {
if ( last ) next;
name = $2;
if (name == "ELAST")
if (name == "ELAST") {
last = 1;
next;
}
number = $4;
if (number < 0 || number == "EAGAIN")
next;