]>
Commit | Line | Data |
---|---|---|
60a23f5a | 1 | #include <dlfcn.h> |
ceaa9889 | 2 | #include <stdlib.h> |
60a23f5a UD |
3 | #include <stdio.h> |
4 | ||
5 | static int | |
6 | do_test (void) | |
7 | { | |
8 | void *h = dlopen ("tst-tlsmod17b.so", RTLD_LAZY); | |
9 | if (h == NULL) | |
10 | { | |
11 | puts ("unexpectedly failed to open tst-tlsmod17b.so"); | |
12 | exit (1); | |
13 | } | |
14 | ||
15 | int (*fp) (void) = (int (*) (void)) dlsym (h, "tlsmod17b"); | |
16 | if (fp == NULL) | |
17 | { | |
18 | puts ("cannot find tlsmod17b"); | |
19 | exit (1); | |
20 | } | |
21 | ||
22 | if (fp ()) | |
23 | exit (1); | |
24 | ||
25 | return 0; | |
26 | } | |
27 | ||
36fe25fd | 28 | #include <support/test-driver.c> |