This is the mail archive of the libc-help@sourceware.org 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]

Re: request for help debugging a segfault in _dl_relocate_object


On Mon, Apr 28, 2008 at 1:26 PM, James Washer <washer@trlp.com> wrote:
> I'm fairly new at digging through libc code and have been trying to
>  determine the cause of a segfault in _dl_relocate_object.
>
>  On a system running RHEL4U6 we have an application coredump from a
>  segfault. glibc-2.3.4-2.38 provides the ld-linux.so that I'm looking at
>
>
>
>  The program in question has done a dlopen on
>  "/opt/netcool/platform/linux2x86/jre_1.5.4/jre/bin/libawt.so" with flags
>  of RTLD_NOW.
>
>  Further up the stack (or down the stack if you prefer) we end up in
>  _dl_relocate_object and segfault on a null pointer. The pointer in
>  question came from
>
>
>  const char *strtab = (const void *) D_PTR (l, l_info[DT_STRTAB]);
>
>  See near the bottom of this disassembly the comment "BANG" showing the
>  instruction that faulted.
>
>  Any pointers (no pun intended) as to why l_info[DT_STRTAB] might be null
>  would be appreciated.

Hi James,

A backtrace would be useful so that we can determine which invocation
_dl_relocate_object() seg faulted.  I'm interested in where the
link_map pointer came from.

Have you tried reproducing this using a more recent GLIBC?  Glibc 2.3
is quite old.

Regarding this:

const char *strtab = (const void *) D_PTR (l, l_info[DT_STRTAB]);

What is NULL; the pointer `l' or the value coming out of l_info[DT_STRTAB]?

Unfortunately x86 asm isn't my strong point but I'll help if I can.

Ryan S. Arnold


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