$NetBSD: patch-ad,v 1.3 2013/03/25 01:59:03 dholland Exp $ - use standard headers - fix void main - change around handling of signal masks (XXX: it is still wrong) --- netmaze.c.orig 1994-04-15 20:34:04.000000000 +0000 +++ netmaze.c @@ -23,16 +23,12 @@ * *********************************************************************/ -#ifndef NeXT - #include -#endif - #include #include #include #include #include -#include +#include #include #include #include @@ -96,7 +92,7 @@ struct sigaction vec,ovec,vecio,ovecio; extern struct timeval notimeout; extern struct fd_mask readmask; -void main(int argc,char **argv) +int main(int argc,char **argv) { int i,nowait=FALSE; @@ -293,6 +289,7 @@ void main(int argc,char **argv) } XCloseDisplay(sm->grafix.display); + return 0; } /***************************/ @@ -383,7 +380,7 @@ static void start_signal(void) #ifdef RS6000 /* ibm rs/6000 */ sigemptyset(&vec.sa_mask); #else - vec.sa_mask = 0; + (void)sigprocmask (SIG_SETMASK, 0, NULL); #endif vec.sa_flags = 0; if ( sigaction(SIGALRM, &vec, &ovec) == -1) perror("SIGALRM\n"); @@ -412,7 +409,7 @@ static void setup_sigchild(void) #ifdef RS6000 /* ibm rs/6000 */ sigemptyset(&vec.sa_mask); #else - vec.sa_mask = 0; + (void)sigprocmask (SIG_SETMASK, 0, NULL); #endif vec.sa_flags = 0; if ( sigaction(SIGCHLD, &vec, NULL) == -1) perror("SIGCHLD\n");