]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - nptl/tst-stdio1.c
Add per-thread cache to malloc
[thirdparty/glibc.git] / nptl / tst-stdio1.c
index 2396e018538f598815168e84c25c987bdcd5f19a..355e716cd3ae4550c2a07d0d57fecdd78f61ab8c 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2017 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
 
 #include <stdio.h>
 #include <unistd.h>
 
+static int do_test (void);
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
 
 static void *tf (void *a)
 {
@@ -39,18 +43,14 @@ do_test (void)
 
   if (pthread_create (&th, NULL, tf, NULL) != 0)
     {
-      write (2, "create failed\n", 14);
+      write_message ("create failed\n");
       _exit (1);
     }
 
-  pthread_join (th, NULL);
+  delayed_exit (1);
+  xpthread_join (th);
 
   puts ("join returned");
 
-  return 0;
+  return 1;
 }
-
-
-#define EXPECTED_SIGNAL SIGALRM
-#define TEST_FUNCTION do_test ()
-#include "../test-skeleton.c"