Date: Tue, 13 Aug 2002 01:40:04 -0700 (PDT) From: Ruslan Ermilov <ru@FreeBSD.org> To: freebsd-bugs@FreeBSD.org Subject: Re: bin/37442 - patch for /bin/sleep Message-ID: <200208130840.g7D8e4D9035494@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/37442; it has been noted by GNATS. From: Ruslan Ermilov <ru@FreeBSD.org> To: "."@babolo.ru Cc: bug-followup@FreeBSD.org Subject: Re: bin/37442 - patch for /bin/sleep Date: Tue, 13 Aug 2002 11:34:51 +0300 --qcHopEYAB45HaUaB Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Aug 13, 2002 at 01:52:41AM +0400, "."@babolo.ru wrote: > Ruslan Ermilov writes: > > The following reply was made to PR bin/37442; it has been noted by GNAT= S. > >=20 > > From: Ruslan Ermilov <ru@FreeBSD.org> > > To: Edwin Groothuis <edwin@mavetju.org> > > Cc: bug-followup@FreeBSD.org > > Subject: Re: bin/37442 - patch for /bin/sleep > > Date: Mon, 12 Aug 2002 20:38:29 +0300 > >=20 > > On Mon, Aug 12, 2002 at 09:04:20PM +1000, Edwin Groothuis wrote: > > > Greetings, > > >=20 > > > "Why me" is what you ask yourself now probably. Mostly because you > > > are the one who made the last changes to sleep.c... nearly three > > > years ago :-/ > > >=20 > > > Could you have please a look at PR bin/37442? > > > (http://www.freebsd.org/cgi/query-pr.cgi?pr=3Dbin/37442) > > >=20 > > > The PR is about a small change in sleep which allows the usage of > > > multipliers: So that 10m is 10 minutes, 3h is three hours and 4d > > > is four days. > > >=20 > > > It doesn't break any current script-usages, it only adds extra > > > flexibility for people who want to use it. > > >=20 > > POSIX.1-2001 clearly documents the sleep(1)'s SYNOPSIS: > > =20 > > : SYNOPSIS > > : sleep time > > =20 > > And requires that: > > =20 > > : DESCRIPTION > > : The sleep utility shall suspend execution for at least > > : the integral number of seconds specified by the time > > : operand. > > =20 > > We are currently "compatible" with POSIX in that we don't violate it > > (POSIX allows the implementation to support more fine-grained sleep, > > just does not require it to). > > =20 > > If we make the change you propose, we will become incompatible with > > POSIX, as the latter requires ``sleep 10m'' to sleep for "at least > > 10 seconds". > As far as I understand any value bigger then 10s is "at least 10 seconds". > So 10m is "at least 10 seconds". > :-) > So, this IS compatible with POSIX >=20 Nope. "at least the integral number of seconds" is not the same as "at least the X seconds". The point is to say that the implementation may choose to support non-integral intervals, as we do. Cheers, --=20 Ruslan Ermilov Sysadmin and DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age --qcHopEYAB45HaUaB Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (FreeBSD) iD8DBQE9WMSrUkv4P6juNwoRArgPAJ46iVsMCBq7n3BHEKCW6VZuqdacDgCfSbLT TIXZkOuwxezcSjRVeLr0ftg= =UYQu -----END PGP SIGNATURE----- --qcHopEYAB45HaUaB-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200208130840.g7D8e4D9035494>