summaryrefslogtreecommitdiff
path: root/librt/clock_nanosleep.c
diff options
context:
space:
mode:
Diffstat (limited to 'librt/clock_nanosleep.c')
-rw-r--r--librt/clock_nanosleep.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/librt/clock_nanosleep.c b/librt/clock_nanosleep.c
index 85db72fb3..eaae75720 100644
--- a/librt/clock_nanosleep.c
+++ b/librt/clock_nanosleep.c
@@ -37,15 +37,21 @@ clock_nanosleep (clockid_t clock_id, int flags, const struct timespec *req,
clock_id = MAKE_PROCESS_CPUCLOCK (0, CPUCLOCK_SCHED);
if (SINGLE_THREAD_P)
+#if defined(__UCLIBC_USE_TIME64__) && defined(__NR_clock_nanosleep_time64)
+ r = INTERNAL_SYSCALL (clock_nanosleep_time64, err, 4, clock_id, flags, req, rem);
+#else
r = INTERNAL_SYSCALL (clock_nanosleep, err, 4, clock_id, flags, req, rem);
+#endif
else
{
#ifdef __NEW_THREADS
int oldstate = LIBC_CANCEL_ASYNC ();
-
+#if defined(__UCLIBC_USE_TIME64__) && defined(__NR_clock_nanosleep_time64)
+ r = INTERNAL_SYSCALL (clock_nanosleep_time64, err, 4, clock_id, flags, req, rem);
+#else
r = INTERNAL_SYSCALL (clock_nanosleep, err, 4, clock_id, flags, req,
rem);
-
+#endif
LIBC_CANCEL_RESET (oldstate);
#endif
}