From 15309fde91b3989a1af139db422acf68e16a9258 Mon Sep 17 00:00:00 2001 From: Dmitriy Ivanov Date: Fri, 22 May 2015 12:34:42 -0700 Subject: [PATCH] Fix RTLD_NEXT lookup for the local_group Linker used to skip RTLD_NEXT within local_group when caller->next is nullptr (which represents load order but not the order within local_group dependency tree) Bug: http://b/21380474 Change-Id: I178fc4657b19bceb871635b177c1df67855b1708 (cherry picked from commit b96ac41b32e61799c48f3fd07831cc168b95068d) --- linker/linker.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linker/linker.cpp b/linker/linker.cpp index 4c98afe6e..f3ca7610d 100644 --- a/linker/linker.cpp +++ b/linker/linker.cpp @@ -980,7 +980,7 @@ const ElfW(Sym)* dlsym_linear_lookup(const char* name, soinfo* start = solist; if (handle == RTLD_NEXT) { - if (caller == nullptr || caller->next == nullptr) { + if (caller == nullptr) { return nullptr; } else { start = caller->next;