OSDN Git Service

Fix dlsym(handle_of_main_executable, ...)
authorDmitriy Ivanov <dimitry@google.com>
Sat, 30 May 2015 20:04:39 +0000 (13:04 -0700)
committerDmitriy Ivanov <dimitry@google.com>
Mon, 1 Jun 2015 21:33:43 +0000 (14:33 -0700)
commitf439b5a3186ca0fef1092f45770abc716da9d87a
treed85508ffcefb14495e90d6e0669440558f753367
parentd70891687d742414d457e41a998726e5eb0a09bd
Fix dlsym(handle_of_main_executable, ...)

  According to man dlopen(3) and posix docs in the case when si is handle
  of the main executable we need to search not only in the executable and its
  dependencies but also in all libraries loaded with RTLD_GLOBAL.

  see also: http://pubs.opengroup.org/onlinepubs/9699919799/functions/dlopen.html

Bug: http://b/21528224
Bug: http://b/17512583
Bug: https://code.google.com/p/android/issues/detail?id=173822
Change-Id: Ib2801367ba48b6f3704da89a6d9f5e6911430013
linker/linker.cpp
tests/dlfcn_test.cpp
tests/libs/Android.mk