about summary refs log tree commit diff
path: root/sysdeps/generic/ldsodefs.h
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/generic/ldsodefs.h')
-rw-r--r--sysdeps/generic/ldsodefs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/generic/ldsodefs.h b/sysdeps/generic/ldsodefs.h
index 2c3ce81dd0..b7d0f9b7e7 100644
--- a/sysdeps/generic/ldsodefs.h
+++ b/sysdeps/generic/ldsodefs.h
@@ -76,7 +76,7 @@ typedef struct link_map *lookup_t;
 /* On some architectures dladdr can't use st_size of all symbols this way.  */
 #define DL_ADDR_SYM_MATCH(L, SYM, MATCHSYM, ADDR) \
   ((ADDR) >= (L)->l_addr + (SYM)->st_value				\
-   && (((SYM)->st_size == 0						\
+   && ((((SYM)->st_shndx == SHN_UNDEF || (SYM)->st_size == 0)		\
 	&& (ADDR) == (L)->l_addr + (SYM)->st_value)			\
        || (ADDR) < (L)->l_addr + (SYM)->st_value + (SYM)->st_size)	\
    && ((MATCHSYM) == NULL || (MATCHSYM)->st_value < (SYM)->st_value))