Path: utzoo!attcan!uunet!cs.utexas.edu!usc!julius.cs.uiuc.edu!rpi!bu.edu!orc!inews!cmdnfs!bhoughto From: bhoughto@cmdnfs.intel.com (Blair P. Houghton) Newsgroups: comp.unix.programmer Subject: Re: pause(2) vs. sigpause(3) Message-ID: <722@inews.intel.com> Date: 31 Oct 90 15:59:20 GMT References: <43321@eerie.acsu.Buffalo.EDU> <717@inews.intel.com> <27817:Oct3104:58:4990@kramden.acf.nyu.edu> Sender: news@inews.intel.com Organization: Intel Corp, Chandler, AZ Lines: 29 In article <27817:Oct3104:58:4990@kramden.acf.nyu.edu> brnstnd@kramden.acf.nyu.edu (Dan Bernstein) writes: >In article <717@inews.intel.com> bhoughto@cmdnfs.intel.com (Blair P. Houghton) writes: >> Why obsoleted a perfectly simple system call with a >> library function? > >Here it's pause(3) and sigpause(2). What machine are you using? A Dyslexia 1990 running Ungodlix -DDEBUG9... I.e., it was a typo. So was 'obsoleted', for you more confused readers out there... >> (BTW, neither of them is ANSI C; I don't know which might >> be in POSIX). > >POSIX imitated the BSD signal facilities, with some helpful additions. >It made sigpause() into sigsuspend(). The difference is that the >argument is a ``sigset_t'' manipulated by macros. I've looked a little harder and tried a few more (seemingly pathological) situations, and it seems `pause()' waits for whatever signals are currently unblocked, and `sigpause(0)' unblocks everything (only for the duration of the wait) and then waits. (sigpause(n) would use n as a signal mask). --Blair "The wonders of skience." -Popeye the Sailor Man