summary refs log tree commit diff
path: root/elf/dl-runtime.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-07-21 06:43:05 +0000
committerUlrich Drepper <drepper@redhat.com>2000-07-21 06:43:05 +0000
commitf53c03c20d6039d78cf1ccb43fbbbe79e0ec7e9e (patch)
treefa9ef879669c57ff5becd3911f5ee26211229ecd /elf/dl-runtime.c
parentd052b31b79a3681db7de04177a55b04354320a61 (diff)
downloadglibc-f53c03c20d6039d78cf1ccb43fbbbe79e0ec7e9e.tar.gz
glibc-f53c03c20d6039d78cf1ccb43fbbbe79e0ec7e9e.tar.xz
glibc-f53c03c20d6039d78cf1ccb43fbbbe79e0ec7e9e.zip
Update.
	* elf/rtld.c: Define _dl_bind_not variable.
	(process_envvars): Recognize LD_BIND_NOT and set _dl_bind_not.
	* elf/dl-support.c: Likewise.
	* sysdeps/generic/ldsodefs.h: Declare _dl_bind_not.
	* elf/dl-runtime.c (fixup): Don't remember looked up value if
	_dl_bind_not.
	(profile_fixup): Likewise.
Diffstat (limited to 'elf/dl-runtime.c')
-rw-r--r--elf/dl-runtime.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/elf/dl-runtime.c b/elf/dl-runtime.c
index bff27e721e..57746092f1 100644
--- a/elf/dl-runtime.c
+++ b/elf/dl-runtime.c
@@ -117,6 +117,9 @@ fixup (
   value = elf_machine_plt_value (l, reloc, value);
 
   /* Finally, fix up the plt itself.  */
+  if (__builtin_expect (_dl_bind_not, 0))
+    return value;
+
   return elf_machine_fixup_plt (l, result, reloc, rel_addr, value);
 }
 #endif
@@ -205,7 +208,8 @@ profile_fixup (
       value = elf_machine_plt_value (l, reloc, value);
 
       /* Store the result for later runs.  */
-      *resultp = value;
+      if (__builtin_expect (! _dl_bind_not, 1))
+	*resultp = value;
     }
 
   (*mcount_fct) (retaddr, value);