From 7a09b8322cab26d6e3da1362d3c74964ae66b5d4 Mon Sep 17 00:00:00 2001 From: Sebastien Hertz Date: Mon, 10 Aug 2015 18:55:34 +0200 Subject: Allow debugging only for apps forked from zygote When starting the runtime from app_process, we only pass JDWP options if starting zygote. It prevents from opening a JDWP connection in non-zygote programs while Android apps (forked from zygote) remain debuggable. Bug: 23050463 Change-Id: If8ea719063a65db4cdeed69a838b52e87b078b08 --- cmds/app_process/app_main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cmds') diff --git a/cmds/app_process/app_main.cpp b/cmds/app_process/app_main.cpp index 449a4ab..2e02382 100644 --- a/cmds/app_process/app_main.cpp +++ b/cmds/app_process/app_main.cpp @@ -304,9 +304,9 @@ int main(int argc, char* const argv[]) } if (zygote) { - runtime.start("com.android.internal.os.ZygoteInit", args); + runtime.start("com.android.internal.os.ZygoteInit", args, zygote); } else if (className) { - runtime.start("com.android.internal.os.RuntimeInit", args); + runtime.start("com.android.internal.os.RuntimeInit", args, zygote); } else { fprintf(stderr, "Error: no class name or --zygote supplied.\n"); app_usage(); -- cgit v1.1