[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: [PATCH 1/6] fix ambiguous errno treating after mktime()
Date: Fri, 29 Aug 2008 18:26:38 -0400
From: Roland Dowdeswell <elric%imrryr.org@localhost>
| Given that system behaviour may change over time, it falls upon
| libraries to ensure that errno is preserved.
No it doesn't, unless errno is specified for a particular function,
it can be altered in any way the function likes.
| I.e. there is no real
| way of knowing a priori if a random libc function will make a system
| call and whether or not a system call is invoked may change over
Testing errno is only a defined operation immediately after a call to
a function which is defined to set errno, and only in the circumstances
where errno is defined as being set (which includes system calls that return
an error indiocator, and a few other functions here and there).
In no other case (including after system calls that succeed) is the
value of errno defined.
Doing anything with errno in mktime() is only necessary (as opposed to
just permitted) if the doc for mktime defines what that function does
Main Index |
Thread Index |