tech-userlevel archive

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

Re: dlopen() and libpthread

On Sun, Oct 21, 2012 at 01:11:27PM +0000, Emmanuel Dreyfus wrote:
> On Fri, Oct 19, 2012 at 11:16:42AM +0200, Joerg Sonnenberger wrote:
> > Because it doesn't work correctly. libc behavior changes etc.
> > Explicitly erroring out is a *huge* improvement over silent corruption
> > as seen many, many times before.
> > 
> > You might want to check if the DSO really needs libpthread, in many
> > cases it isn't. E.g. if it just wants to use mutexes etc, but doesn't
> > create threads itself, the libc stubs are good enough.
> It seems to only use pthread_mutex, but when building without -lpthread, 
> it does not work anymore: OpenSC clients cannot access  the token anymore
> (ssh-agent gets "no slots").

Try changing src/pkcs11/pkcs11-global.c, line 47 to use sizeof(*m) to
not overflow the buffer as start...


Home | Main Index | Thread Index | Old Index