From: Andreas Jaeger Date: Fri, 14 Apr 2000 00:15:38 +0000 (+0000) Subject: 2000-04-13 Andreas Jaeger X-Git-Tag: glibc-2.16-ports-before-merge~2491 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=043351e023f7ef40e955e450ffdbe8dcbaecbd6c;p=thirdparty%2Fglibc.git 2000-04-13 Andreas Jaeger * sysdeps/mips/dl-machine.h (elf_machine_got_rel): Only add runtime display if needed. --- diff --git a/sysdeps/mips/dl-machine.h b/sysdeps/mips/dl-machine.h index fecd3e17f98..960b6b78d13 100644 --- a/sysdeps/mips/dl-machine.h +++ b/sysdeps/mips/dl-machine.h @@ -504,10 +504,15 @@ elf_machine_got_rel (struct link_map *map, int lazy) generated by gnu ld. Skip these reserved entries from relocation. */ i = (got[1] & ELF_MIPS_GNU_GOT1_MASK)? 2: 1; n = map->l_info[DT_MIPS (LOCAL_GOTNO)]->d_un.d_val; - /* Add the run-time display to all local got entries. */ - while (i < n) - got[i++] += map->l_addr; - + /* Add the run-time display to all local got entries if needed. */ + if (map->l_addr != 0) + { + while (i < n) + got[i++] += map->l_addr; + } + else + i = n; + /* Handle global got entries. */ got += n; sym = (void *) D_PTR (map, l_info[DT_SYMTAB]);