Move dlsym and dladdr implementation to linker.cpp
Bug: http://b/25716705 Bug: http://b/22865643 Change-Id: If22fc1eda219f676b5fcc06490f7901d21d1749c
This commit is contained in:
@@ -760,7 +760,7 @@ TEST(dlfcn, dlsym_failures) {
|
||||
// so it can be distinguished from the NULL handle.
|
||||
sym = dlsym(nullptr, "test");
|
||||
ASSERT_TRUE(sym == nullptr);
|
||||
ASSERT_SUBSTR("dlsym library handle is null", dlerror());
|
||||
ASSERT_STREQ("dlsym failed: library handle is null", dlerror());
|
||||
#endif
|
||||
|
||||
// NULL symbol name.
|
||||
@@ -768,7 +768,7 @@ TEST(dlfcn, dlsym_failures) {
|
||||
// glibc marks this parameter non-null and SEGVs if you cheat.
|
||||
sym = dlsym(self, nullptr);
|
||||
ASSERT_TRUE(sym == nullptr);
|
||||
ASSERT_SUBSTR("", dlerror());
|
||||
ASSERT_STREQ("dlsym failed: symbol name is null", dlerror());
|
||||
#endif
|
||||
|
||||
// Symbol that doesn't exist.
|
||||
|
||||
Reference in New Issue
Block a user