summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Gampe <agampe@google.com>2017-05-10 18:53:02 -0700
committerAndreas Gampe <agampe@google.com>2017-05-15 19:51:29 -0700
commit4c88a8c6848609333fa6058fcfc22ac58ed94dac (patch)
treed106bd1697331e00d5fb7a7f041a06288b44ca19
parent73818566d6cdab38b96a9a6dbf773f11b166526c (diff)
downloadbase-4c88a8c6848609333fa6058fcfc22ac58ed94dac.tar.gz
Zygote: Allow arbitrary-length wrap property names
The restriction on system property key length has been lifted. Update the invoke-with code to first check the full-length property. Then fall back to the truncated version for backwards-compatibility. Test: m Test: manual with long package name (Maps) Change-Id: I9f714af093a6017307cfef18c84de769f0de7c3e
-rw-r--r--core/java/com/android/internal/os/ZygoteConnection.java8
1 files changed, 0 insertions, 8 deletions
diff --git a/core/java/com/android/internal/os/ZygoteConnection.java b/core/java/com/android/internal/os/ZygoteConnection.java
index 527582be3c02..91429a609288 100644
--- a/core/java/com/android/internal/os/ZygoteConnection.java
+++ b/core/java/com/android/internal/os/ZygoteConnection.java
@@ -717,14 +717,6 @@ class ZygoteConnection {
public static void applyInvokeWithSystemProperty(Arguments args) {
if (args.invokeWith == null && args.niceName != null) {
String property = "wrap." + args.niceName;
- if (property.length() > 31) {
- // Properties with a trailing "." are illegal.
- if (property.charAt(30) != '.') {
- property = property.substring(0, 31);
- } else {
- property = property.substring(0, 30);
- }
- }
args.invokeWith = SystemProperties.get(property);
if (args.invokeWith != null && args.invokeWith.length() == 0) {
args.invokeWith = null;