Lines Matching refs:handle

134   ZipArchiveHandle handle;  in TEST_F()  local
135 ASSERT_EQ(0, OpenArchive(lib_path.c_str(), &handle)); in TEST_F()
137 ASSERT_EQ(0, FindEntry(handle, kLibZipSimpleZip, &zip_entry)); in TEST_F()
139 CloseArchive(handle); in TEST_F()
200 void* handle = dlopen("libdlext_test.so", RTLD_NOW); in TEST() local
201 ASSERT_DL_NOTNULL(handle); in TEST()
207 ASSERT_TRUE(handle != handle2); in TEST()
210 dlclose(handle); in TEST()
218 void* handle = dlopen(symlink_name.c_str(), RTLD_NOW); in TEST() local
219 ASSERT_DL_NOTNULL(handle); in TEST()
228 ASSERT_TRUE(handle == handle2); in TEST()
231 dlclose(handle); in TEST()
262 void* handle = dlopen((lib_path + "!/libdir/libatest_simple_zip.so").c_str(), RTLD_NOW); in TEST() local
263 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
265 …uint32_t* taxicab_number = reinterpret_cast<uint32_t*>(dlsym(handle, "dlopen_testlib_taxicab_numbe… in TEST()
269 dlclose(handle); in TEST()
276 void* handle = dlopen((lib_path + "!/libdir/libtest_dt_runpath_d_zip.so").c_str(), RTLD_NOW); in TEST() local
278 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
281 dlopen_b_fn fn = (dlopen_b_fn)dlsym(handle, "dlopen_b"); in TEST()
288 dlclose(handle); in TEST()
301 void* handle = dlopen("libdlext_test_zip.so", RTLD_NOW); in TEST() local
302 ASSERT_TRUE(handle == nullptr); in TEST()
306 handle = dlopen("libdlext_test_zip.so", RTLD_NOW); in TEST()
307 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
310 fn = reinterpret_cast<int (*)(void)>(dlsym(handle, "getRandomNumber")); in TEST()
315 reinterpret_cast<uint32_t*>(dlsym(handle, "dlopen_testlib_taxicab_number")); in TEST()
319 dlclose(handle); in TEST()
465 void* handle = android_dlopen_ext(lib, RTLD_NOW, &extinfo_); in CreateRelroFile() local
466 if (handle == nullptr) { in CreateRelroFile()
470 fn f = reinterpret_cast<fn>(dlsym(handle, "getRandomNumber")); in CreateRelroFile()
475 fn f = reinterpret_cast<fn>(dlsym(handle, "getBiggerRandomNumber")); in CreateRelroFile()
481 reinterpret_cast<uint32_t*>(dlsym(handle, "dlopen_testlib_taxicab_number")); in CreateRelroFile()
664 void* handle; in SpawnChildrenAndMeasurePss() local
666 handle = android_dlopen_ext(lib, RTLD_NOW, &extinfo_); in SpawnChildrenAndMeasurePss()
668 handle = dlopen(lib, RTLD_NOW); in SpawnChildrenAndMeasurePss()
670 if (handle == nullptr) { in SpawnChildrenAndMeasurePss()
785 void* handle = dlopen(g_public_lib, RTLD_NOW); in TEST() local
786 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
787 dlclose(handle); in TEST()
794 handle = android_dlopen_ext(lib_public_path.c_str(), RTLD_NOW, &extinfo); in TEST()
795 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
796 ASSERT_TRUE(handle == handle_public); in TEST()
798 dlclose(handle); in TEST()
808 handle = android_dlopen_ext(lib_public_path.c_str(), RTLD_NOW, &extinfo); in TEST()
809 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
812 ASSERT_TRUE(handle == handle_public); in TEST()
814 dlclose(handle); in TEST()
818 handle = android_dlopen_ext(lib_public_path.c_str(), RTLD_NOW, &extinfo); in TEST()
819 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
820 ASSERT_TRUE(handle == handle_public); in TEST()
822 dlclose(handle); in TEST()
833 handle = android_dlopen_ext(lib_public_path.c_str(), RTLD_NOW, &extinfo); in TEST()
834 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
838 ASSERT_TRUE(handle != handle_public); in TEST()
840 dlclose(handle); in TEST()
953 void* handle = android_dlopen_ext("foobar", RTLD_NOW, &extinfo); in TEST() local
955 ASSERT_DL_NOTNULL(handle); in TEST()
957 …uint32_t* taxicab_number = reinterpret_cast<uint32_t*>(dlsym(handle, "dlopen_testlib_taxicab_numbe… in TEST()
960 dlclose(handle); in TEST()
1001 void* handle = android_dlopen_ext("foobar", RTLD_NOW, &extinfo); in TEST() local
1003 ASSERT_DL_NOTNULL(handle); in TEST()
1005 …uint32_t* taxicab_number = reinterpret_cast<uint32_t*>(dlsym(handle, "dlopen_testlib_taxicab_numbe… in TEST()
1008 dlclose(handle); in TEST()
1032 void* handle = android_dlopen_ext(root_lib, RTLD_NOW, &extinfo); in TEST() local
1033 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1039 reinterpret_cast<fn_t>(dlsym(handle, "ns_get_internal_extern_string")); in TEST()
1044 reinterpret_cast<fn_t>(dlsym(handle, "internal_extern_string")); in TEST()
1081 void* handle = android_dlopen_ext(root_lib, RTLD_NOW, &extinfo); in TEST() local
1082 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1088 reinterpret_cast<fn_t>(dlsym(handle, "ns_get_internal_extern_string")); in TEST()
1095 reinterpret_cast<fn_t>(dlsym(handle, "internal_extern_string")); in TEST()
1132 void* handle = android_dlopen_ext(root_lib, RTLD_NOW, &extinfo); in TEST() local
1133 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1135 dlclose(handle); in TEST()
1137 handle = android_dlopen_ext(root_lib, RTLD_NOW | RTLD_NOLOAD, &extinfo); in TEST()
1138 ASSERT_TRUE(handle == nullptr); in TEST()
1144 handle = android_dlopen_ext(g_public_lib, RTLD_NOW | RTLD_NOLOAD, &extinfo); in TEST()
1145 ASSERT_TRUE(handle == nullptr); in TEST()
1181 void* handle = android_dlopen_ext((public_ns_search_path + "/libtest_missing_symbol.so").c_str(), in TEST() local
1184 ASSERT_TRUE(handle == nullptr); in TEST()
1224 void* handle = android_dlopen_ext("libtest_missing_symbol_root.so", RTLD_NOW, &extinfo); in TEST() local
1225 ASSERT_TRUE(handle == nullptr); in TEST()
1252 void* handle = android_dlopen_ext("libnativehelper.so", RTLD_NOW, &extinfo); in TEST() local
1253 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1256 void* dlsym_ptr = dlsym(handle, "dlsym"); in TEST()
1260 dlclose(handle); in TEST()
1264 handle = android_dlopen_ext("libnativehelper.so", RTLD_NOW, &extinfo); in TEST()
1265 ASSERT_TRUE(handle == nullptr); in TEST()
1289 void* handle = android_dlopen_ext("libnativehelper.so", RTLD_NOW, &extinfo); in TEST() local
1290 ASSERT_TRUE(handle == nullptr); in TEST()
1328 void* handle = android_dlopen_ext("libthatdoesnotexist.so", RTLD_NOW, &extinfo); in TEST() local
1329 ASSERT_TRUE(handle == nullptr); in TEST()
1383 void* handle = dlopen(lib_private_external_path.c_str(), RTLD_NOW); in TEST() local
1384 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1516 void* handle = android_dlopen_ext(lib_private_external_path.c_str(), RTLD_NOW, &extinfo); in TEST() local
1517 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1622 void* handle = android_dlopen_ext("libnstest_private.so", RTLD_NOW, &extinfo); in TEST() local
1623 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1624 …const char** ns_private_extern_string = static_cast<const char**>(dlsym(handle, "g_private_extern_… in TEST()
1628 dlclose(handle); in TEST()
1633 void* handle = android_dlopen_ext( in TEST() local
1638 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1639 …const char** ns_public_extern_string = static_cast<const char**>(dlsym(handle, "g_public_extern_st… in TEST()
1643 dlclose(handle); in TEST()
1648 void* handle = android_dlopen_ext( in TEST() local
1653 ASSERT_TRUE(handle == nullptr); in TEST()
1683 void* handle = android_dlopen_ext("libnstest_dlopened.so", RTLD_NOW | RTLD_NOLOAD, &extinfo); in TEST() local
1684 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
1685 ASSERT_TRUE(handle == handle_dlopened); in TEST()
1686 dlclose(handle); in TEST()
1690 handle = android_dlopen_ext("libnstest_dlopened.so", RTLD_NOW | RTLD_NOLOAD, &extinfo); in TEST()
1691 ASSERT_TRUE(handle == nullptr) in TEST()
1694handle = android_dlopen_ext((GetTestlibRoot() + "/private_namespace_libs/libnstest_dlopened.so").c… in TEST()
1696 ASSERT_TRUE(handle == nullptr) in TEST()
1699 handle = dlopen("libnstest_dlopened.so", RTLD_NOW | RTLD_NOLOAD); in TEST()
1700 ASSERT_TRUE(handle == nullptr) in TEST()
1703 handle = dlopen((GetTestlibRoot() + "/private_namespace_libs/libnstest_dlopened.so").c_str(), in TEST()
1705 ASSERT_TRUE(handle == nullptr) in TEST()
1715 handle = android_dlopen_ext(g_public_lib, RTLD_NOW | RTLD_NOLOAD, &extinfo); in TEST()
1716 ASSERT_TRUE(handle == nullptr) in TEST()
1834 void* handle = android_dlopen_ext(library_path.c_str(), RTLD_NOW, &extinfo); in TEST() local
1835 ASSERT_TRUE(handle == nullptr); in TEST()
1996 void* handle = android_dlopen_ext(private_library_absolute_path.c_str(), RTLD_NOW, &extinfo); in TEST() local
1997 ASSERT_TRUE(handle != nullptr) << dlerror(); in TEST()
2000 reinterpret_cast<uintptr_t>(dlsym(handle, "ns_get_dlopened_string")); in TEST()
2095 void* handle = dlopen("libtest_dlsym_from_this.so", RTLD_NOW | RTLD_LOCAL); in TEST() local
2096 ASSERT_TRUE((reinterpret_cast<uintptr_t>(handle) & 1) != 0) in TEST()
2098 dlclose(handle); in TEST()
2103 void* handle = dlopen("libtest_dlsym_from_this.so", RTLD_NOW | RTLD_LOCAL); in TEST() local
2104 ASSERT_TRUE(reinterpret_cast<uintptr_t>(handle) % sizeof(uintptr_t) == 0) in TEST()
2106 dlclose(handle); in TEST()