This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: dlopen/dlclose behaviour - real reloading from disk required.
- From: "Carlos O'Donell" <carlos at systemhalted dot org>
- To: Petr Baudis <pasky at suse dot cz>
- Cc: Przemysław Firszt <przemo at firszt dot eu>, libc-help at sourceware dot org
- Date: Fri, 11 Dec 2009 09:42:14 -0500
- Subject: Re: dlopen/dlclose behaviour - real reloading from disk required.
- References: <1260388032.3122.13.camel@pldmachine> <20091211023547.GC2249@machine.or.cz>
2009/12/10 Petr Baudis <pasky@suse.cz>:
>> How can I force real reloading of the modified version?
>>
>> I can provide a test case if someone wants to check it.
>
> That would be good. I'm not completely familiar with ld.so innards, but
> according to dlclose() documentation, it might be that some other
> library still keeps the refcount up... You could also try to watch in
> detail what ld.so does by setting $LD_DEBUG appropriately (see man
> ld.so).
Note that no object which is the target of relocation may be removed
by dlclose, unless the object which had the relocation is itself also
unloaded. If your plugin resolved a relocation from another object, it
will never be unloaded. So keep that in mind.
Cheers,
Carlos.