OSDN Git Service

Check if idmap2 is accessible before executing it.
authorYabin Cui <yabinc@google.com>
Wed, 27 Feb 2019 00:12:46 +0000 (16:12 -0800)
committerYabin Cui <yabinc@google.com>
Thu, 28 Feb 2019 22:54:14 +0000 (14:54 -0800)
commita60dc9e51dd02b5394523934f1a40434d67afab2
tree95c5c963633ff2e0f63fe09eaee7e57ddca030f8
parent89b58a49e96c61f8657413478684c3df714c195a
Check if idmap2 is accessible before executing it.

When wrap.sh is used in a debuggable app, AssetManager tries to execute
idmap2 in the app's security context, not in zygote context. And idmap2
isn't allowed to execute in the app's context, thus making an abort.

The abort makes Android studio can't debug the app. To avoid the abort,
check if idmap2 is accessible before executing it.

Bug: 124109020
Test: test manually that android studio can debug the app with this
Test: change.

Change-Id: I82d772358b2266433f82319896a4ca662cc3c273
core/jni/android_util_AssetManager.cpp