From owner-freebsd-current Tue Aug 12 15:05:46 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id PAA24417 for current-outgoing; Tue, 12 Aug 1997 15:05:46 -0700 (PDT) Received: from phaeton.artisoft.com (phaeton.Artisoft.COM [198.17.250.50]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id PAA24407 for ; Tue, 12 Aug 1997 15:05:34 -0700 (PDT) Received: (from terry@localhost) by phaeton.artisoft.com (8.6.11/8.6.9) id PAA07903; Tue, 12 Aug 1997 15:00:11 -0700 From: Terry Lambert Message-Id: <199708122200.PAA07903@phaeton.artisoft.com> Subject: Re: siginterrupt (was Re: Error in sleep !) To: ache@nagual.pp.ru (=?KOI8-R?B?4c7E0sXKIP7F0s7P1w==?=) Date: Tue, 12 Aug 1997 15:00:11 -0700 (MST) Cc: terry@lambert.org, sos@sos.freebsd.dk, current@FreeBSD.ORG In-Reply-To: from "=?KOI8-R?B?4c7E0sXKIP7F0s7P1w==?=" at Aug 13, 97 01:54:52 am X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > > By default, in traditional BSD, after a signal, the call was > > restarted. > > > > This man page is incorrect about the default for FreeBSD; so > > is the signal man page. > > As I check, man page says that it will be restarted for FreeBSD too. > What is incorrect here? I just check signal.c and see that SA_RESTART > is set unless expicitly disabled by siginterrupt(3)... The claim is that FreeBSD defaults have been brought into concordance with POSIX. And the man pages have not been updated. To the original poster: The system call restart of a sleep(3) does *not* guarantee that the elapsed time is subtracted from the argument when the restart is initiated (ie: if you sleep for 2 of 3 seconds, get a signal, and restart, the restart will likely be for another 3 seconds -- not the remaining 1). So depending on this behaviour is probably an error, in any case. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.