]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - nptl/tst-join5.c
Add per-thread cache to malloc
[thirdparty/glibc.git] / nptl / tst-join5.c
index 7f95bd1ea576ef0687e6e2a8b30cfe11b9379dae..7a9fa750fe3ac7752a926262805a916e1281c853 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2003-2014 Free Software Foundation, Inc.
+/* Copyright (C) 2003-2017 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@redhat.com>, 2003.
 
 #include <stdlib.h>
 #include <time.h>
 #include <unistd.h>
-#include <sys/syscall.h>
 
 
-#define wait_code()                                                          \
-  do {                                                                       \
-    struct timespec ts = { .tv_sec = 0, .tv_nsec = 200000000 };                      \
-    while (syscall (__NR_nanosleep, &ts, &ts) < 0)                           \
-      /* nothing */;                                                         \
-  } while (0)
+static void
+wait_code (void)
+{
+  struct timespec ts = { .tv_sec = 0, .tv_nsec = 200000000 };
+  while (nanosleep (&ts, &ts) < 0)
+    ;
+}
 
 
 #ifdef WAIT_IN_CHILD