--- mstools/h/errno.h 2018/08/09 18:20:01 1.1.1.1 +++ mstools/h/errno.h 2018/08/09 18:23:02 1.1.1.4 @@ -1,7 +1,7 @@ /*** *errno.h - system wide error numbers (set by system calls) * -* Copyright (c) 1985-1990, Microsoft Corporation. All rights reserved. +* Copyright (c) 1985-1993, Microsoft Corporation. All rights reserved. * *Purpose: * This file defines the system-wide error numbers (set by @@ -18,14 +18,33 @@ extern "C" { #endif -#if (_MSC_VER <= 600) -#define __cdecl _cdecl +/* + * Conditional macro definition for function calling type and variable type + * qualifiers. + */ +#if ( (_MSC_VER >= 800) && (_M_IX86 >= 300) ) + +/* + * Definitions for MS C8-32 (386/486) compiler + */ +#define _CRTAPI1 __cdecl +#define _CRTAPI2 __cdecl + +#else + +/* + * Other compilers (e.g., MIPS) + */ +#define _CRTAPI1 +#define _CRTAPI2 + #endif + /* declare reference to errno */ #ifdef _MT -extern int * _errno(void); +extern int * _CRTAPI1 _errno(void); #define errno (*_errno()) #else extern int errno; @@ -33,7 +52,6 @@ extern int errno; /* Error Codes */ -#define EZERO 0 #define EPERM 1 #define ENOENT 2 #define ESRCH 3 @@ -48,7 +66,6 @@ extern int errno; #define ENOMEM 12 #define EACCES 13 #define EFAULT 14 -#define ENOTBLK 15 #define EBUSY 16 #define EEXIST 17 #define EXDEV 18 @@ -59,7 +76,6 @@ extern int errno; #define ENFILE 23 #define EMFILE 24 #define ENOTTY 25 -#define ETXTBSY 26 #define EFBIG 27 #define ENOSPC 28 #define ESPIPE 29 @@ -68,8 +84,17 @@ extern int errno; #define EPIPE 32 #define EDOM 33 #define ERANGE 34 -#define EUCLEAN 35 -#define EDEADLOCK 36 +#define EDEADLK 36 +#define ENAMETOOLONG 38 +#define ENOLCK 39 +#define ENOSYS 40 +#define ENOTEMPTY 41 +#define EILSEQ 42 + +/* + * Support EDEADLOCK for compatibiity with older MS-C versions. + */ +#define EDEADLOCK EDEADLK #ifdef __cplusplus }