From: Ulrich Drepper Date: Mon, 2 Mar 1998 11:35:33 +0000 (+0000) Subject: (dladdr): Remove duplicate code. X-Git-Tag: cvs/before-sparc-2_0_x-branch~194 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3b41ee05b213fe8217a2e3bea22cf66d0b969f20;p=thirdparty%2Fglibc.git (dladdr): Remove duplicate code. --- diff --git a/elf/dladdr.c b/elf/dladdr.c index 868a0ed893f..55b9caf7300 100644 --- a/elf/dladdr.c +++ b/elf/dladdr.c @@ -43,16 +43,13 @@ dladdr (void *address, Dl_info *info) size_t n = match->l_phnum; if (n > 0) { - if (n > 0) - { - do - --n; - while (match->l_phdr[n].p_type != PT_LOAD); - if (addr >= (match->l_addr + - match->l_phdr[n].p_vaddr + match->l_phdr[n].p_memsz)) - /* Off the end of the highest-addressed shared object. */ - return 0; - } + do + --n; + while (match->l_phdr[n].p_type != PT_LOAD); + if (addr >= (match->l_addr + + match->l_phdr[n].p_vaddr + match->l_phdr[n].p_memsz)) + /* Off the end of the highest-addressed shared object. */ + return 0; } } else