summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2009-09-14 00:14:22 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2009-09-14 00:14:22 +0000
commite7de563acf2b05afcce38c9d2354c0a76237de0d (patch)
treef3cb0d5287da768bd77f24b1e91df697ddebbb52 /cpukit
parent2009-09-13 Joel Sherrill <joel.sherrill@OARcorp.com> (diff)
downloadrtems-e7de563acf2b05afcce38c9d2354c0a76237de0d.tar.bz2
2009-09-13 Joel Sherrill <joel.sherrill@oarcorp.com>
* posix/src/nanosleep.c: Disable EINTR case when POSIX is disabled because it cannot happen.
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/ChangeLog5
-rw-r--r--cpukit/posix/src/nanosleep.c12
2 files changed, 13 insertions, 4 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog
index fcdd522da4..ee8574a1ee 100644
--- a/cpukit/ChangeLog
+++ b/cpukit/ChangeLog
@@ -1,3 +1,8 @@
+2009-09-13 Joel Sherrill <joel.sherrill@oarcorp.com>
+
+ * posix/src/nanosleep.c: Disable EINTR case when POSIX is disabled
+ because it cannot happen.
+
2009-09-13 Joel Sherrill <joel.sherrill@OARcorp.com>
* score/inline/rtems/score/coremsg.inl: Fix compilation issue when
diff --git a/cpukit/posix/src/nanosleep.c b/cpukit/posix/src/nanosleep.c
index cd66175df7..e83f1c8277 100644
--- a/cpukit/posix/src/nanosleep.c
+++ b/cpukit/posix/src/nanosleep.c
@@ -93,11 +93,15 @@ int nanosleep(
_Timespec_From_ticks( ticks, rmtp );
/*
- * If there is time remaining, then we were interrupted by a signal.
+ * Only when POSIX is enabled, can a sleep be interrupted.
*/
-
- if ( ticks )
- rtems_set_errno_and_return_minus_one( EINTR );
+ #if defined(RTEMS_POSIX_API)
+ /*
+ * If there is time remaining, then we were interrupted by a signal.
+ */
+ if ( ticks )
+ rtems_set_errno_and_return_minus_one( EINTR );
+ #endif
}
return 0;