Mail Archives: cygwin-developers/1998/04/20/00:24:05
Hi!
Newlib-980310 sources contains old buggy include/machine/setjmp.h -
sigjmp_buf defined as a structure instead of an array for __CYGWIN32__. The
correct definition must be
#ifdef __CYGWIN32__
#include <signal.h>
/* POSIX sigsetjmp/siglongjmp macros */
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]),\
setjmp (env))
#define siglongjmp(env, val) (((env[_SAVEMASK])?\
sigprocmask (SIG_SETMASK, (sigset_t *) &env[_SIGMASK], 0):0),\
longjmp (env, val))
#endif /* __CYGWIN32__*/
--
Sergey Okhapkin, http://www.lexa.ru/sos
Moscow, Russia.
- Raw text -