about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/i386/dl-machine.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/i386/dl-machine.h b/sysdeps/i386/dl-machine.h
index bdca6bec3b..7c22305307 100644
--- a/sysdeps/i386/dl-machine.h
+++ b/sysdeps/i386/dl-machine.h
@@ -77,7 +77,7 @@ elf_machine_rel (struct link_map *map,
 		 Elf32_Addr sym_loadaddr, const Elf32_Sym *sym)
 {
   Elf32_Addr *const reloc_addr = (void *) (map->l_addr + reloc->r_offset);
-  const Elf32_Addr sym_value = sym_loadaddr + sym->st_value;
+  const Elf32_Addr sym_value = sym ? sym_loadaddr + sym->st_value : 0;
 
   switch (ELF32_R_TYPE (reloc->r_info))
     {