Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site seismo.CSS.GOV Path: utzoo!watmath!clyde!bonnie!akgua!gatech!seismo!keith From: keith@seismo.CSS.GOV (Keith Bostic) Newsgroups: net.bugs.2bsd Subject: CSS/Harvard 2.9BSD bug report #6 Message-ID: <210@seismo.CSS.GOV> Date: Wed, 18-Sep-85 01:34:31 EDT Article-I.D.: seismo.210 Posted: Wed Sep 18 01:34:31 1985 Date-Received: Thu, 19-Sep-85 05:30:09 EDT Organization: Center for Seismic Studies, Arlington, VA Lines: 81 Keywords: tstp.c, libcurses, signal Subject: libcurses has some missing signal calls Index: usr.lib/libcurses/tstp.c 2.9BSD Description: Libcurses compiles fine, but includes some illegal system calls. Repeat-By: Load libcurses with a program that includes the routine tstp(). Fix: Comment out the offending calls. Honest. Diff follows. *** tstp.c.right Mon Aug 26 00:18:33 1985 --- tstp.c.wrong Fri Jun 7 11:17:28 1985 *************** *** 32,38 endwin(); fflush(stdout); /* reset signal handler so kill below stops us */ signal(SIGTSTP, SIG_DFL); #define mask(s) (1 << ((s)-1)) omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); --- 32,37 ----- endwin(); fflush(stdout); /* reset signal handler so kill below stops us */ + #ifndef pdp11 signal(SIGTSTP, SIG_DFL); #define mask(s) (1 << ((s)-1)) omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); *************** *** 36,42 signal(SIGTSTP, SIG_DFL); #define mask(s) (1 << ((s)-1)) omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); kill(0, SIGTSTP); #ifndef pdp11 sigblock(mask(SIGTSTP)); --- 35,40 ----- signal(SIGTSTP, SIG_DFL); #define mask(s) (1 << ((s)-1)) omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); + #endif !pdp11 kill(0, SIGTSTP); sigblock(mask(SIGTSTP)); signal(SIGTSTP, tstp); *************** *** 38,44 omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); #endif !pdp11 kill(0, SIGTSTP); sigblock(mask(SIGTSTP)); #endif pdp11 signal(SIGTSTP, tstp); --- 36,41 ----- #define mask(s) (1 << ((s)-1)) omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); kill(0, SIGTSTP); + #ifndef pdp11 sigblock(mask(SIGTSTP)); signal(SIGTSTP, tstp); _tty = tty; *************** *** 40,46 kill(0, SIGTSTP); #ifndef pdp11 sigblock(mask(SIGTSTP)); signal(SIGTSTP, tstp); _tty = tty; stty(_tty_ch, &_tty); --- 37,42 ----- omask = sigsetmask(sigblock(0) &~ mask(SIGTSTP)); kill(0, SIGTSTP); sigblock(mask(SIGTSTP)); + #endif pdp11 signal(SIGTSTP, tstp); _tty = tty; stty(_tty_ch, &_tty);