Paul Eggert
d1bc398fa0
(main): Use getopt_long rather than getopt.
2004-11-17 00:56:25 +00:00
Jim Meyering
4e1cbbdb67
(main): Remove declaration of unused local, c.
2004-10-18 07:52:19 +00:00
Paul Eggert
4ef2590268
Remove now-unused long-options static var.
...
(main): Use getopt where it suffices, not getopt_long.
2004-09-21 22:09:09 +00:00
Paul Eggert
9d581705a7
(apply_suffix): Use bool for booleans.
2004-08-02 22:19:27 +00:00
Jim Meyering
1ce7b61d0e
(main): Standardize on the diagnostics given when someone gives
...
too few operands ("missing operand after `xxx'") or
too many operands ("extra operand `xxx'").
Include "quote.h" and/or "error.h" if it wasn't already being included.
2004-06-21 15:03:35 +00:00
Jim Meyering
eb5ac5fa4a
(usage): Use EXIT_SUCCESS, not 0, for clarity.
2004-01-21 23:44:47 +00:00
Jim Meyering
6b18b46eae
Include "c-strtod.h".
...
(main): Update xstrtod call to include new argument, c_strtod.
2003-11-27 08:16:38 +00:00
Jim Meyering
df81ab2911
Cast NULL to `(char *)' in call to variadic function,
...
parse_long_options, so that it works even on systems for which
sizeof char* != sizeof int.
2003-11-05 03:53:19 +00:00
Jim Meyering
cf4fdf373f
Most .c files (AUTHORS): Revert the WRITTEN_BY/AUTHORS change
...
of 2003-09-19. Now, AUTHORS is a comma-separated list of strings.
Update the call to parse_long_options so that `AUTHORS, NULL' are the
last parameters.
* src/true.c (main): Append NULL to version_etc argument list.
* src/sys2.h (case_GETOPT_VERSION_CHAR): Likewise.
2003-10-18 10:05:47 +00:00
Jim Meyering
bafd927f03
(WRITTEN_BY): Rename from AUTHORS.
...
Begin each WRITTEN_BY string with `Written by ' and end it with `.'.
Mark each WRITTEN_BY string as translatable.
2003-09-18 22:19:03 +00:00
Jim Meyering
c6ec144494
revert previous change
2003-09-18 19:39:12 +00:00
Jim Meyering
3280bf4b55
Update AUTHORS definition to be a comma-separated list of strings and/or update
...
the call to parse_long_options so that `AUTHORS, NULL' are the last parameters.
2003-09-18 18:22:23 +00:00
Jim Meyering
4f4e9aa8e1
Don't include headers already included by system.h:
...
Don't include closeout.h.
2003-07-23 07:29:54 +00:00
Jim Meyering
6bcd4b08ba
(main): Call initialize_main.
2003-06-17 18:13:23 +00:00
Jim Meyering
3e9e352991
Remove now-unused #include and #define directives.
2003-03-08 14:30:28 +00:00
Jim Meyering
1e8f677ed4
Factor nanosleep-related code into ../lib/xnanosleep.c.
...
Include xnanosleep.h.
Factor out fenv.h-related code.
(timespec_subtract): Remove function.
(main): Remove code that deals with computing start and stop times
as well as the loop around nanosleep. Now that's in xnanosleep.c.
2002-09-12 12:01:02 +00:00
Jim Meyering
4006f4e672
Change exit (0)' to exit (EXIT_SUCCESS)',
...
`exit (1)' to `exit (EXIT_FAILURE)', and
`usage (1)' to `usage (EXIT_FAILURE)'.
2002-08-31 08:52:10 +00:00
Jim Meyering
7488703199
Change error (1, ...' to error (EXIT_FAILURE, ...'.
2002-08-30 23:04:53 +00:00
Jim Meyering
2ee11887cd
(usage): Use the PACKAGE_BUGREPORT e-mail address, rather than hard-coding it.
2002-07-02 09:09:10 +00:00
Jim Meyering
a25f0cdb7e
reflect renaming: nanosleep.h -> timespec.h
2002-03-01 23:34:23 +00:00
Jim Meyering
2fae9e5d26
Use new macros, HELP_OPTION_DESCRIPTION and VERSION_OPTION_DESCRIPTION
...
instead of hard-coding --help and --version descriptions.
Split --help output into smaller pieces.
Use fputs, not printf.
2001-12-15 20:46:30 +00:00
Jim Meyering
9e1b4e382a
(usage): Indent --help and --version strings to start in the 7th column.
2001-11-25 14:46:05 +00:00
Jim Meyering
1e4a6cbe1c
(AUTHORS): Mark string for translation, since it contains the English word `and'.
2001-08-14 07:10:10 +00:00
Jim Meyering
70e5178bde
(usage): Don't call close_stdout directly, since that
...
didn't cover --version output.
(main): Arrange to call close_stdout via atexit, instead.
2000-05-11 07:21:33 +00:00
Jim Meyering
661f74698e
Include "closeout.h".
...
(usage): Call close_stdout just before exit.
2000-05-07 15:00:12 +00:00
Jim Meyering
21b43e0fe9
add blank line
2000-01-06 08:35:45 +00:00
Jim Meyering
2315cbdeaa
(apply_suffix): Comment.
2000-01-06 08:35:21 +00:00
Jim Meyering
eee26242bb
fix typo in comment
2000-01-06 08:29:10 +00:00
Jim Meyering
757861331e
Minor code cleanup.
...
(clock_get_realtime): Return argument, for convenience.
(main): Use this to simplify main sleep loop.
2000-01-06 08:28:39 +00:00
Jim Meyering
fd0797a4e4
Include nanosleep.h.
...
(AUTHORS): Add Paul Eggert.
2000-01-05 12:17:59 +00:00
Jim Meyering
3b979cf095
Add #pragma STDC FENV_ACCESS ON if C99.
...
(<fenv.h>): Include if available.
(main): Always round floating-point interval calculations upwards,
as we must sleep for at least the specified time.
Do the right thing with NaNs.
2000-01-05 12:17:19 +00:00
Jim Meyering
34c324d786
update usage
2000-01-02 09:31:15 +00:00
Jim Meyering
99c51ad97e
minor var. renamings
1999-12-27 16:30:20 +00:00
Jim Meyering
64003d937b
Use < rather than >.
...
(main): Normalize ts_stop.
1999-12-25 20:00:21 +00:00
Jim Meyering
0ecbb73025
(USE_CLOCK_GETTIME): Define.
...
[USE_CLOCK_GETTIME]: Include sys/time.h.
(timespec_subtract): New function.
(clock_get_realtime): New function.
(sighandler): Remove function.
(main): Reimplement again, using nanosleep and clock_gettime.
1999-12-23 14:34:38 +00:00
Jim Meyering
7769c416ef
tweak comment
1999-12-19 15:51:32 +00:00
Jim Meyering
c077ecf83c
tweak comment
1999-12-19 15:21:19 +00:00
Jim Meyering
062906c83a
Don't include math.h or float.h.
...
Don't use DBL_MAX.
Use TIME_T_MAX instead.
1999-11-28 19:59:18 +00:00
Jim Meyering
b9c91d0570
don't include assert.h
1999-11-28 14:04:12 +00:00
Jim Meyering
e20a9b89d2
Round more carefully so we never call nanosleep with more than 999,999,999
...
nanoseconds.
Comment out assertion because it uses on EINTR.
1999-11-28 14:03:43 +00:00
Jim Meyering
0baa523154
Rewrite to use nanosleep (hence, timer stops when sleep is suspended)
...
and to remove gettimeofday/signal cruft.
Improve overflow checking.
1999-11-28 13:35:00 +00:00
Jim Meyering
d5f7b2a2db
*** empty log message ***
1999-11-28 08:08:51 +00:00
Jim Meyering
4c05896b20
better error checking
...
add FIXME comments for non-portable constructs
1999-11-28 08:00:58 +00:00
Jim Meyering
ec974f5c39
remove another printf stmt
1999-11-27 20:03:05 +00:00
Jim Meyering
15d2e7a86b
remove printf stmts
1999-11-27 20:02:38 +00:00
Jim Meyering
069610a0f0
fix typos
1999-11-27 20:01:22 +00:00
Jim Meyering
5617251659
Rewrite to allow fractional seconds and to handle SIGCONT.
...
(main): Rewrite.
(sighandler): New function.
(apply_suffix): New function.
(timeval_subtract): New function.
1999-11-27 20:00:54 +00:00
Jim Meyering
398516f242
(usage): Add elipses to show that sleep allows more than one argument.
1999-11-27 17:10:15 +00:00
Jim Meyering
6b36a017db
(argdecode): Move definition to precede use.
...
Remove prototype.
1999-11-27 15:02:27 +00:00
Jim Meyering
33bebae5ae
(usage): Correct --help message.
1999-08-30 14:38:00 +00:00