From ad7534c8f08c31f3e140a31e4099e7e0b5e193d2 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Fri, 25 Aug 2000 19:33:19 +0000 Subject: Update. 2000-08-25 Ulrich Drepper * elf/Makefile (LDFLAGS-nodelete): Add -rdynamic. * elf/nodelete.c (fini_ran): New global variable. (do_test): Before every dlclose call clear fini_ran and test afterwards that it is not set by the destructors. * elf/nodelmod1.c: Add destructor which sets fini_ran. * elf/nodelmod2.c: Likewise. * elf/nodelmod4.c: Likewise. --- elf/nodelmod4.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'elf/nodelmod4.c') diff --git a/elf/nodelmod4.c b/elf/nodelmod4.c index 55eb6e6dda..2cca43a6e8 100644 --- a/elf/nodelmod4.c +++ b/elf/nodelmod4.c @@ -1 +1,9 @@ int var_in_mod4 = 99; + +static void +__attribute__ ((__destructor__)) +destr (void) +{ + extern int fini_ran; + fini_ran = 1; +} -- cgit v1.2.3-65-gdbad