guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: stime.c forcing errno


From: Paul Jarc
Subject: Re: stime.c forcing errno
Date: Fri, 13 Feb 2004 22:58:33 -0500
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3 (gnu/linux)

I wrote:
> So for localtime/gmtime, set errno beforehand just in case libc fails
> to conform.  But for mktime/strptime, test for failure afterwards and
> set errno in that case.  Setting it beforehand may not help; since
> these functions are not documented to have any particular effect on
> errno, they might have any effect at all - such as replacing our
> EINVAL with something nonsensical.

It would also be ok to test afterwards for localtime/gmtime as well.
POSIX says they should set errno, but the C standard doesn't, so that
might be a good idea.


paul




reply via email to

[Prev in Thread] Current Thread [Next in Thread]