* libc/include/machine/setjmp.h: Protect sigsetjmp/siglongjmp macro arguments.
* libc/include/sys/errno.h: Declare sys_errlist and sys_nerr, under Cygwin.
This commit is contained in:
parent
6a574f1ad6
commit
4acf3edf6a
|
@ -1,3 +1,11 @@
|
|||
Mon Aug 13 22:26:01 2001 Christopher Faylor <cgf@cygnus.com>
|
||||
|
||||
* libc/include/machine/setjmp.h: Protect sigsetjmp/siglongjmp macro
|
||||
arguments.
|
||||
|
||||
* libc/include/sys/errno.h: Declare sys_errlist and sys_nerr, under
|
||||
Cygwin.
|
||||
|
||||
2001-08-13 Jeff Johnston <jjohnstn@redhat.com>
|
||||
|
||||
* libc/include/malloc.h (M_MXFAST, M_NLBLKS, M_GRAIN, M_KEEP): New
|
||||
|
|
|
@ -161,12 +161,16 @@ typedef int sigjmp_buf[_JBLEN+2];
|
|||
#define _SAVEMASK _JBLEN
|
||||
#define _SIGMASK (_JBLEN+1)
|
||||
|
||||
#define sigsetjmp(env, savemask) (env[_SAVEMASK] = savemask,\
|
||||
sigprocmask (SIG_SETMASK, 0, (sigset_t *) &env[_SIGMASK]),\
|
||||
#ifdef __CYGWIN__
|
||||
# define _CYGWIN_WORKING_SIGSETJMP
|
||||
#endif
|
||||
|
||||
#define sigsetjmp(env, savemask) ((env)[_SAVEMASK] = savemask,\
|
||||
sigprocmask (SIG_SETMASK, 0, (sigset_t *) ((env) + _SIGMASK)),\
|
||||
setjmp (env))
|
||||
|
||||
#define siglongjmp(env, val) (((env[_SAVEMASK])?\
|
||||
sigprocmask (SIG_SETMASK, (sigset_t *) &env[_SIGMASK], 0):0),\
|
||||
#define siglongjmp(env, val) ((((env)[_SAVEMASK])?\
|
||||
sigprocmask (SIG_SETMASK, (sigset_t *) ((env) + _SIGMASK), 0):0),\
|
||||
longjmp (env, val))
|
||||
|
||||
#endif /* __CYGWIN__ or __rtems__ */
|
||||
|
|
|
@ -17,6 +17,10 @@ extern int *__errno _PARAMS ((void));
|
|||
|
||||
extern __IMPORT _CONST char * _CONST _sys_errlist[];
|
||||
extern __IMPORT int _sys_nerr;
|
||||
#ifdef __CYGWIN__
|
||||
extern __IMPORT const char * const sys_errlist[];
|
||||
extern __IMPORT int sys_nerr;
|
||||
#endif
|
||||
|
||||
#define __errno_r(ptr) ((ptr)->_errno)
|
||||
|
||||
|
|
Loading…
Reference in New Issue