* times.cc (settimeofday): Add EFAULT handler.

Set errno to EINVAL if tv.tv_nsec is invalid, and to EPERM if
SetSystemTime fails.  Return -1 in case of failure, all for
compatibility with BSD and Linux.
(clock_settime): New function.
* cygwin.din (clock_settime): Export.
* posix.sgml (std-susv4): Add clock_settime.
Move clock_setres from here...
(std-deprec): ... to here.
(std-notes): Correct limitation of clock_setres to only CLOCK_REALTIME.
Add limitation of clock_settime to only CLOCK_REALTIME.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
This commit is contained in:
Yaakov Selkowitz
2011-05-09 08:57:46 +00:00
parent b6a46e417b
commit 6758d2a3aa
5 changed files with 53 additions and 7 deletions

View File

@ -409,12 +409,13 @@ details. */
pthread_getattr_np.
242: Export psiginfo, psignal, sys_siglist.
243: Export sysinfo.
244: Export clock_settime.
*/
/* Note that we forgot to bump the api for ualarm, strtoll, strtoull */
#define CYGWIN_VERSION_API_MAJOR 0
#define CYGWIN_VERSION_API_MINOR 243
#define CYGWIN_VERSION_API_MINOR 244
/* There is also a compatibity version number associated with the
shared memory regions. It is incremented when incompatible