|
|
147e83 |
nptl/tst-audit-threads: Switch to <support/test-driver.c>
|
|
|
147e83 |
|
|
|
147e83 |
The downstream version of test-skeleton.c does not include
|
|
|
147e83 |
<support/support.h> for backwards compatibility reasons, leading to a
|
|
|
147e83 |
compilation failure:
|
|
|
147e83 |
|
|
|
147e83 |
tst-audit-threads.c: In function 'do_test':
|
|
|
147e83 |
tst-audit-threads.c:87:3: error: implicit declaration of function 'xcalloc' [-Werror=implicit-function-declaration]
|
|
|
147e83 |
threads = (pthread_t *) xcalloc (num_threads, sizeof(pthread_t));
|
|
|
147e83 |
^
|
|
|
147e83 |
tst-audit-threads.c:87:13: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
|
|
|
147e83 |
threads = (pthread_t *) xcalloc (num_threads, sizeof(pthread_t));
|
|
|
147e83 |
^
|
|
|
147e83 |
|
|
|
147e83 |
diff --git a/nptl/tst-audit-threads.c b/nptl/tst-audit-threads.c
|
|
|
147e83 |
index e4bf433bd85f3715..42742d51e4bc06a3 100644
|
|
|
147e83 |
--- a/nptl/tst-audit-threads.c
|
|
|
147e83 |
+++ b/nptl/tst-audit-threads.c
|
|
|
147e83 |
@@ -25,19 +25,12 @@
|
|
|
147e83 |
the relocation resolution caching code in the dynamic loader i.e.
|
|
|
147e83 |
_dl_runtime_profile and _dl_profile_fixup. */
|
|
|
147e83 |
|
|
|
147e83 |
+#include <support/support.h>
|
|
|
147e83 |
#include <support/xthread.h>
|
|
|
147e83 |
#include <strings.h>
|
|
|
147e83 |
#include <stdlib.h>
|
|
|
147e83 |
#include <sys/sysinfo.h>
|
|
|
147e83 |
|
|
|
147e83 |
-static int do_test (void);
|
|
|
147e83 |
-
|
|
|
147e83 |
-/* This test usually takes less than 3s to run. However, there are cases that
|
|
|
147e83 |
- take up to 30s. */
|
|
|
147e83 |
-#define TIMEOUT 60
|
|
|
147e83 |
-#define TEST_FUNCTION do_test ()
|
|
|
147e83 |
-#include "../test-skeleton.c"
|
|
|
147e83 |
-
|
|
|
147e83 |
/* Declare the functions we are going to call. */
|
|
|
147e83 |
#define externnum
|
|
|
147e83 |
#include "tst-audit-threads.h"
|
|
|
147e83 |
@@ -95,3 +88,8 @@ do_test (void)
|
|
|
147e83 |
|
|
|
147e83 |
return 0;
|
|
|
147e83 |
}
|
|
|
147e83 |
+
|
|
|
147e83 |
+/* This test usually takes less than 3s to run. However, there are cases that
|
|
|
147e83 |
+ take up to 30s. */
|
|
|
147e83 |
+#define TIMEOUT 60
|
|
|
147e83 |
+#include <support/test-driver.c>
|