]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
sleep: Overhaul.
authorDag-Erling Smørgrav <des@FreeBSD.org>
Mon, 25 Mar 2024 15:58:31 +0000 (16:58 +0100)
committerDag-Erling Smørgrav <des@FreeBSD.org>
Mon, 25 Mar 2024 15:59:02 +0000 (16:59 +0100)
commit2295cae7e606d75016575927c3d8729745abb17a
tree5932ef3519f200865d9c10a1c2ff38faefbadf50
parentcaccf6d3c008d3c778986734c2705cdae849a877
sleep: Overhaul.

Program:

* Add a dummy getopt(3) loop to handle `--`.
* Move interval parsing out into a separate function.
* Print a diagnostic for every invalid interval.
* Check for NaN and infinity.
* Improve bounds checks.

Manual page:

* Miscellaneous markup fixes.
* Reword DESCRIPTION section.
* Move text about GNU compatibility to STANDARDS section.
* Convert examples from csh to sh.

Sponsored by: Klara, Inc.
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D44471
bin/sleep/sleep.1
bin/sleep/sleep.c