mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-30 08:40:07 +00:00
249fd241a2
1999-08-02 Thorsten Kukuk <kukuk@suse.de> * nis/nis_callback.c (internal_nis_do_callback) use poll() instead of select(). 1999-08-02 Ulrich Drepper <drepper@cygnus.com> * sysdeps/generic/s_nextafter.c: Define __nexttoward and nexttoward so something else so that aliasing works. 1999-08-02 Thorsten Kukuk <kukuk@suse.de> * sysdeps/generic/math_ldbl.h: Fix typo. * sysdeps/generic/strtold.c: Remove unbalanced #endif. * sysdeps/alpha/fpu/e_sqrt.c: Use new path for e_sqrt.c. 1999-08-02 Ulrich Drepper <drepper@cygnus.com> * elf/resolvfail.c: Include stdio.h. Also test dlerror.
32 lines
501 B
C
32 lines
501 B
C
#include <dlfcn.h>
|
|
#include <stdio.h>
|
|
|
|
static const char obj[] = "testobj1.so";
|
|
|
|
int
|
|
main (void)
|
|
{
|
|
void *d = dlopen (obj, RTLD_LAZY);
|
|
int n;
|
|
|
|
if (d == NULL)
|
|
{
|
|
printf ("cannot load %s: %s\n", obj, dlerror ());
|
|
return 1;
|
|
}
|
|
|
|
for (n = 0; n < 10000; ++n)
|
|
if (dlsym (d, "does not exist") != NULL)
|
|
{
|
|
puts ("dlsym() did not fail");
|
|
return 1;
|
|
}
|
|
else if (dlerror () == NULL)
|
|
{
|
|
puts ("dlerror() didn't return a string");
|
|
return 1;
|
|
}
|
|
|
|
return 0;
|
|
}
|