소스 검색

fix bug in dladdr that prevented resolving addresses in the PLT

Rich Felker 12 년 전
부모
커밋
cdc5c74c6a
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/ldso/dynlink.c

+ 1 - 1
src/ldso/dynlink.c

@@ -1188,7 +1188,7 @@ int __dladdr(void *addr, Dl_info *info)
 	}
 
 	for (; nsym; nsym--, sym++) {
-		if (sym->st_shndx && sym->st_value
+		if (sym->st_value
 		 && (1<<(sym->st_info&0xf) & OK_TYPES)
 		 && (1<<(sym->st_info>>4) & OK_BINDS)) {
 			void *symaddr = p->base + sym->st_value;