- status: open --> open-fixed
If clock_nanosleep( ) fails, it shall return the
corresponding error value, not -1.
The patch is in CVS now.
patch:
=========================
RCS
file: /home/cvs/components/cglvalidation/misc/posixtests
uite/src/PTS/conformance/interfaces/clock_nanosleep/11
-1.c,v
retrieving revision 1.1.1.2
diff -u -r1.1.1.2 11-1.c
--- 11-1.c 21 May 2003 01:44:54 -0000 1.1.1.2
+++ 11-1.c 7 Jan 2004 11:42:25 -0000
@@ -39,13 +39,9 @@
for (i=0; i<NUMINVALIDTESTS;i++) {
tssleep.tv_nsec=invalid_tests[i];
printf("sleep %d\n", invalid_tests[i]);
- if (clock_nanosleep(CLOCK_REALTIME, 0,
&tssleep, NULL) == -1) {
- if (EINVAL != errno) {
- printf("errno != EINVAL\n");
- failure = 1;
- }
- } else {
- printf("clock_nanosleep() did not
return -1 \n");
+ if (clock_nanosleep(CLOCK_REALTIME, 0,
&tssleep, NULL)
+ != EINVAL) {
+ printf("errno != EINVAL\n");
failure = 1;
}
}