On Fri, May 3, 2013 at 8:11 AM, Simon Richter <s...@debian.org> wrote:

> I'm writing a small preload library to trace pthread_* calls ...
> In order to find the original function, I use dlsym(RTLD_NEXT, ...) ...

> In any case, I am wondering if it is actually possible to redirect the
> pthread_* functions in this way, or if a different approach is required.

In general: no. You can't expect dlsym() to not call any pthread_*
functions. Even if this happens to work today for some versions of
glibc on Linux, there is absolutely no guarantee that it will continue
to work tomorrow.


-- 
Paul Pluzhnikov

Reply via email to