aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/riscv
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/riscv')
-rw-r--r--sysdeps/riscv/dl-machine.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/riscv/dl-machine.h b/sysdeps/riscv/dl-machine.h
index 0cbb476..b2f2869 100644
--- a/sysdeps/riscv/dl-machine.h
+++ b/sysdeps/riscv/dl-machine.h
@@ -348,7 +348,7 @@ elf_machine_runtime_setup (struct link_map *l, struct r_scope_elem *scope[],
gotplt[1] = (ElfW(Addr)) l;
}
- if (l->l_type == lt_executable && l->l_scope != NULL)
+ if (l->l_type == lt_executable && l->l_relocated)
{
/* The __global_pointer$ may not be defined by the linker if the
$gp register does not be used to access the global variable