about summary refs log tree commit diff
path: root/elf/dl-sym.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/dl-sym.c')
-rw-r--r--elf/dl-sym.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/elf/dl-sym.c b/elf/dl-sym.c
index 84236ff993..8ab6f2c64e 100644
--- a/elf/dl-sym.c
+++ b/elf/dl-sym.c
@@ -74,7 +74,7 @@ RTLD_NEXT used in code not dynamically loaded"));
 	}
     }
 
-  if (result)
+  if (ref)
     return DL_SYMBOL_ADDRESS (result, ref);
 
   return NULL;
@@ -130,7 +130,7 @@ RTLD_NEXT used in code not dynamically loaded"));
 					    map->l_local_scope, &vers, 0);
     }
 
-  if (result)
+  if (ref)
     return DL_SYMBOL_ADDRESS (result, ref);
   return NULL;
 }