This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: Optimize dlopen failure (Re: PATCH: Fix the dlopen failure)


On Sun, Jun 30, 2002 at 01:14:26AM -0700, Ulrich Drepper wrote:
> On Thu, 2002-05-30 at 14:34, H . J . Lu wrote:
> > During dlopen, _dl_relocate_object may fail when something goes wrong.
> > But l_opencount isn't updated yet. When that happens, you get memory
> > corruption. This patch fixes it.
> 
> Please don't keep for yourself what this is supposed to fix.  I cannot
> apply the patch without knowing this.  Just saying "memory corruption"
> isn't enough.  What's the code path?
> 

I submitted a testcase for it:

http://sources.redhat.com/ml/libc-alpha/2002-06/msg00051.html

It should be fixed now. I will double check.

I am enclosing a new patch which optimizes dlopen in case of failure.
There is no need to check args.map->l_searchlist.r_list[0] since it
should be the same as args.map.



H.J.

Attachment: glibc-close.patch
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]