1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
|
#ifndef _MY_SIGNAL_STUBS_H
#define _MY_SIGNAL_STUBS_H
#ifdef _MSC_VER
/*
* Define missing signal constants for Windows
* These aren't used functionally but are included to make the code compile
*/
#ifndef SIGALRM
#define SIGALRM 14
#endif
#ifndef SIGHUP
#define SIGHUP 1
#endif
#ifndef SIGPIPE
#define SIGPIPE 13
#endif
#ifndef SIGQUIT
#define SIGQUIT 3
#endif
#ifndef SIGTSTP
#define SIGTSTP 18
#endif
#ifndef SIGTTIN
#define SIGTTIN 21
#endif
#ifndef SIGTTOU
#define SIGTTOU 22
#endif
/* Define sigaction struct for Windows */
struct sigaction {
void (*sa_handler)(int);
void (*sa_sigaction)(int, void*, void*);
int sa_flags;
void* sa_mask;
};
/* Define empty function stubs */
#define sigemptyset(set) (0)
#define sigaction(sig, act, oact) (0)
#endif /* _MSC_VER */
#endif /* _MY_SIGNAL_STUBS_H */
|