Cruft: There are 3 routines that convert time_t to text

Gary E. Miller gem at rellim.com
Wed Mar 15 19:04:33 UTC 2017


Yo Hal!

On Wed, 15 Mar 2017 11:50:30 -0700
Hal Murray <hmurray at megapathdsl.net> wrote:

> You can remove that out of range check.  ctl_pitfs is only called
> twice to print the time of the last leap second and the expiration
> time of the file. They should be sane.  We can add a sanity check but
> there is already a checksum on the file.  I'd be happy with strange
> looking printout as long as it doesn't crash.

I like checks for things that can never happen.  Somehow many of them
eventually do get tripped, then the error is more obvious, assuming a
good error message.

It also makes an auitor's life easier, all he needs to know about overflow
and rangning is all tested in the same locality.  It took you a while
connect that path from front to back, it should not need that much work.
Especially in a seldom used piece of code.

RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
	gem at rellim.com  Tel:+1 541 382 8588

	    Veritas liberabit vos. -- Quid est veritas?
    "If you can’t measure it, you can’t improve it." - Lord Kelvin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ntpsec.org/pipermail/devel/attachments/20170315/b84ef59e/attachment.bin>


More information about the devel mailing list