#include #include #include #include #include #define TRUE 0 #define FALSE -1 #define SIGUSR3 9 void catcher(int sig); struct sigaction sigact; void main(void){ printf("** TESTSVR1: シグナル受信用 **\n"); getchar(); sigemptyset(&sigact.sa_mask); sigact.sa_flags = 0; sigact.sa_handler = catcher; sigaction(SIGUSR1, &sigact, NULL); sigaction(SIGUSR2, &sigact, NULL); sigaction(SIGUSR3, &sigact, NULL); printf("* シグナルを待機します。 \n"); getchar(); } /********************/ void catcher(int sig) /********************/ { system("DSPLIBL *PRINT"); errno = 0; return; }