tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: dlopen(3) and symbol conflicts

On Thu, Mar 19, 2015 at 02:24:30PM +0000, Emmanuel Dreyfus wrote:
> On Thu, Mar 19, 2015 at 03:09:54PM +0100, Joerg Sonnenberger wrote:
> > On Thu, Mar 19, 2015 at 01:26:35PM +0000, Emmanuel Dreyfus wrote:
> > > But that looks like a dlopen() problem: modtest is linked with -ltest,
> > > libtest is loaded by dlopen, I can call other functions in it. 
> > > Why a libtest's symbol fails to override a libc's weak symbols? It
> > > looks like a bug to me.
> > 
> > Because  it has been resolved already?
> We do resolve all symbols, even the one that the program do not use?

Lazy loading is optional. If it has been used at the time is hard to
say. Symbol interposition is further complicated by how dlopen is used,
e.g. global vs local namespace. In short: really, don't do this.


Home | Main Index | Thread Index | Old Index