mirror of
https://sourceware.org/git/glibc.git
synced 2025-01-03 16:21:06 +00:00
(main): Don't perform the test if __dso_handle is not available.
This commit is contained in:
parent
9672b9372f
commit
719404ef2e
@ -21,6 +21,8 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
|
||||
extern void *__dso_handle __attribute__ ((__weak__));
|
||||
|
||||
int
|
||||
main (void)
|
||||
{
|
||||
@ -29,6 +31,12 @@ main (void)
|
||||
void (*fp) (void *);
|
||||
int v = 0;
|
||||
|
||||
if (&__dso_handle == NULL)
|
||||
{
|
||||
puts ("__dso_handle not available, cannot perform the test");
|
||||
exit (0);
|
||||
}
|
||||
|
||||
h = dlopen (fname, RTLD_NOW);
|
||||
if (h == NULL)
|
||||
{
|
||||
|
@ -20,6 +20,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
extern void *__dso_handle __attribute__ ((__weak__));
|
||||
|
||||
int
|
||||
main (void)
|
||||
@ -29,6 +30,12 @@ main (void)
|
||||
void (*fp) (void *);
|
||||
int v = 0;
|
||||
|
||||
if (&__dso_handle == NULL)
|
||||
{
|
||||
puts ("__dso_handle not available, cannot perform the test");
|
||||
exit (0);
|
||||
}
|
||||
|
||||
h = dlopen (fname, RTLD_LAZY);
|
||||
if (h == NULL)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user