Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 812d188a authored by Makoto Onuki's avatar Makoto Onuki
Browse files

Intern process names.

Bug: 62144301
Test: Boot and start random apps on a secondary user
Change-Id: I8a9b475410c52e1063cff5519b0297ad69dd7925
parent b4dcdd5f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2976,7 +2976,7 @@ public class PackageParser {
        if (procSeq == null || procSeq.length() <= 0) {
            return defProc;
        }
        return buildCompoundName(pkg, procSeq, "process", outError);
        return TextUtils.safeIntern(buildCompoundName(pkg, procSeq, "process", outError));
    }

    private static String buildTaskAffinityName(String pkg, String defProc,
+8 −0
Original line number Diff line number Diff line
@@ -483,6 +483,14 @@ public class TextUtils {
        return isEmpty(s) ? 0 : s.length();
    }

    /**
     * @return interned string if it's null.
     * @hide
     */
    public static String safeIntern(String s) {
        return (s != null) ? s.intern() : null;
    }

    /**
     * Returns the length that the specified CharSequence would have if
     * spaces and ASCII control characters were trimmed from the start and end,