Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b83b46d

Browse files
committed
MSL errno.h has moved some errors around, and doesn't document
them in comments, so we do that ourselves.
1 parent 4346716 commit b83b46d

3 files changed

Lines changed: 24 additions & 6 deletions

File tree

Mac/scripts/errors.txt

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -579,12 +579,12 @@
579579
32 EPIPE Broken pipe
580580
33 EDOM Numerical argument out of domain
581581
34 ERANGE Result too large
582-
35 EAGAIN Resource temporarily unavailable
583-
36 EINPROGRESS Operation now in progress
584-
37 EALREADY Operation already in progress
585-
38 ENOTSOCK Socket operation on non-socket
586-
39 EDESTADDRREQ Destination address required
587-
40 EMSGSIZE Message too long
582+
35 EFPOS File positioning error
583+
36 ESIGPARM Signal argument error
584+
37 ENOMEM Cannot allocate memory
585+
38 EACCES Permission denied
586+
39 ENOENT No such file or directory
587+
40 ENOSYS Function not implemented
588588
41 EPROTOTYPE Protocol wrong type for socket
589589
42 ENOPROTOOPT Protocol not available
590590
43 EPROTONOSUPPORT Protocol not supported
@@ -624,3 +624,8 @@
624624
77 ENOLCK No locks available
625625
78 ENOSYS Function not implemented
626626
79 EFTYPE Inappropriate file type or format
627+
136 EINPROGRESS Operation now in progress
628+
137 EALREADY Operation already in progress
629+
138 ENOTSOCK Socket operation on non-socket
630+
139 EDESTADDRREQ Destination address required
631+
140 EMSGSIZE Message too long

Mac/scripts/mkestrres-errno.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
/* These are defined in MSL errno.h, but unfortunately not documented */
2+
#define EFPOS 35 /* File positioning error */
3+
#define ESIGPARM 36 /* Signal argument error */
4+
#define ENOMEM 37 /* Cannot allocate memory */
5+
#define EACCES 38 /* Permission denied */
6+
#define ENOENT 39 /* No such file or directory */
7+
#define ENOSYS 40 /* Function not implemented */

Mac/scripts/mkestrres.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,12 @@ def main():
9090
parse_errno_h(fp, dict)
9191
fp.close()
9292

93+
fss, ok = macfs.PromptGetFile("Select 2nd errno.h or cancel")
94+
if not ok: return
95+
fp = open(fss.as_pathname())
96+
parse_errno_h(fp, dict)
97+
fp.close()
98+
9399
fss, ok = macfs.PromptGetFile("Where is Errors.h?")
94100
if not ok: return
95101
fp = open(fss.as_pathname())

0 commit comments

Comments
 (0)