]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(dladdr): Remove duplicate code.
authorUlrich Drepper <drepper@redhat.com>
Mon, 2 Mar 1998 11:35:33 +0000 (11:35 +0000)
committerUlrich Drepper <drepper@redhat.com>
Mon, 2 Mar 1998 11:35:33 +0000 (11:35 +0000)
elf/dladdr.c

index 868a0ed893ff0e5c29b2e1d0b8c089c009572781..55b9caf7300bd8bcf469058197d59a861abaa4de 100644 (file)
@@ -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