[Top][All Lists]

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

Bug#196085: Problem in glibc-2.3.2/elf/do-lookup.h

From: Ognyan Kulev
Subject: Bug#196085: Problem in glibc-2.3.2/elf/do-lookup.h
Date: Thu, 05 Jun 2003 16:48:30 +0300
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3.1) Gecko/20030527 Debian/1.3.1-2

Ognyan Kulev wrote:
This bug is reassigned to libc0.3. The problem seems to be that glibc-2.3.2/elf/do-lookup.h:do_lookup signals SEGV when SCOPE array is empty. I don't know the semantics of these data structures, but if it's allowed this array to be empty, then the attached patch will solve the problem. (I'm not able to test it right now, but it's so simple...)

Here is the forgotten patch. BTW The crash, that this bug is about, happens when scope->r_list == NULL (and scope->r_nlist == 0).

Ognyan Kulev <ogi@fmi.uni-sofia.bg>, "\"Programmer\""
7D9F 66E6 68B7 A62B 0FCF  EB04 80BF 3A8C A252 9782
2003-06-05  Ognyan Kulev  <ogi@fmi.uni-sofia.bg>

        * elf/do-lookup.h: Check if SCOPE array is empty.
--- glibc-2.3.2/elf/do-lookup.h.orig    2003-06-05 15:44:26.000000000 +0300
+++ glibc-2.3.2/elf/do-lookup.h 2003-06-05 15:45:00.000000000 +0300
@@ -37,6 +37,9 @@ FCT (const char *undef_name, unsigned lo
   size_t n = scope->r_nlist;
   struct link_map *map;
+  if (i >= n)
+    return 0;
       const ElfW(Sym) *symtab;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]