Merge "Ignore signal registration for debugging"

This commit is contained in:
TreeHugger Robot
2019-07-15 21:34:42 +00:00
committed by Android (Google) Code Review
2 changed files with 11 additions and 0 deletions

View File

@@ -106,6 +106,14 @@ public final class Zygote {
*/
public static final int USE_APP_IMAGE_STARTUP_CACHE = 1 << 16;
/**
* When set, application specified signal handlers are not chained (i.e, ignored)
* by the runtime.
*
* Used for debugging only. Usage: set debug.ignoreappsignalhandler to 1.
*/
public static final int DEBUG_IGNORE_APP_SIGNAL_HANDLER = 1 << 17;
/** No external storage should be mounted. */
public static final int MOUNT_EXTERNAL_NONE = IVold.REMOUNT_MODE_NONE;
/** Default external storage should be mounted. */

View File

@@ -1526,6 +1526,9 @@ public final class ProcessList {
if ("1".equals(SystemProperties.get("debug.assert"))) {
runtimeFlags |= Zygote.DEBUG_ENABLE_ASSERT;
}
if ("1".equals(SystemProperties.get("debug.ignoreappsignalhandler"))) {
runtimeFlags |= Zygote.DEBUG_IGNORE_APP_SIGNAL_HANDLER;
}
if (mService.mNativeDebuggingApp != null
&& mService.mNativeDebuggingApp.equals(app.processName)) {
// Enable all debug flags required by the native debugger.