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

Commit e714927b authored by Narayan Kamath's avatar Narayan Kamath
Browse files

Partially revert commit ff5659fb.

ff5659fb was intended to be a clean revert of 660cf30e
that fixed a DOA issue. However, the author incorrectly rebased that
revert and picked up pieces of a separate change as well. This reverts
those sections of the change so that they can be submitted with the
correct attribution and with proper review.

Bug: 34415265
Bug: 34914977
Test: make

Change-Id: I977c3ba10bb05f04ac8cfd95d17954c454c83340
parent 7a1c94cc
Loading
Loading
Loading
Loading
+6 −6
Original line number Original line Diff line number Diff line
@@ -2747,15 +2747,15 @@ public class PackageParser {
        String cls = clsSeq.toString();
        String cls = clsSeq.toString();
        char c = cls.charAt(0);
        char c = cls.charAt(0);
        if (c == '.') {
        if (c == '.') {
            return pkg + cls;
            return (pkg + cls).intern();
        }
        }
        if (cls.indexOf('.') < 0) {
        if (cls.indexOf('.') < 0) {
            StringBuilder b = new StringBuilder(pkg);
            StringBuilder b = new StringBuilder(pkg);
            b.append('.');
            b.append('.');
            b.append(cls);
            b.append(cls);
            return b.toString();
            return b.toString().intern();
        }
        }
        return cls;
        return cls.intern();
    }
    }


    private static String buildCompoundName(String pkg,
    private static String buildCompoundName(String pkg,
@@ -2775,7 +2775,7 @@ public class PackageParser {
                        + pkg + ": " + nameError;
                        + pkg + ": " + nameError;
                return null;
                return null;
            }
            }
            return pkg + proc;
            return (pkg + proc).intern();
        }
        }
        String nameError = validateName(proc, true, false);
        String nameError = validateName(proc, true, false);
        if (nameError != null && !"system".equals(proc)) {
        if (nameError != null && !"system".equals(proc)) {
@@ -2783,7 +2783,7 @@ public class PackageParser {
                    + pkg + ": " + nameError;
                    + pkg + ": " + nameError;
            return null;
            return null;
        }
        }
        return proc;
        return proc.intern();
    }
    }


    private static String buildProcessName(String pkg, String defProc,
    private static String buildProcessName(String pkg, String defProc,
@@ -5101,7 +5101,7 @@ public class PackageParser {
            if (v != null) {
            if (v != null) {
                if (v.type == TypedValue.TYPE_STRING) {
                if (v.type == TypedValue.TYPE_STRING) {
                    CharSequence cs = v.coerceToString();
                    CharSequence cs = v.coerceToString();
                    data.putString(name, cs != null ? cs.toString() : null);
                    data.putString(name, cs != null ? cs.toString().intern() : null);
                } else if (v.type == TypedValue.TYPE_INT_BOOLEAN) {
                } else if (v.type == TypedValue.TYPE_INT_BOOLEAN) {
                    data.putBoolean(name, v.data != 0);
                    data.putBoolean(name, v.data != 0);
                } else if (v.type >= TypedValue.TYPE_FIRST_INT
                } else if (v.type >= TypedValue.TYPE_FIRST_INT