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

Commit 3ec5f97a authored by Narayan Kamath's avatar Narayan Kamath Committed by Android (Google) Code Review
Browse files

Merge "Conditionally include org.apache.http.legacy in app classpaths."

parents de873a64 e2d2ed49
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -2760,9 +2760,17 @@ public class PackageParser {
            }
        }

        addSharedLibrariesForBackwardCompatibility(owner);

        return true;
    }

    private static void addSharedLibrariesForBackwardCompatibility(Package owner) {
        if (owner.applicationInfo.targetSdkVersion <= Build.VERSION_CODES.LOLLIPOP_MR1) {
            owner.usesLibraries = ArrayUtils.add(owner.usesLibraries, "org.apache.http.legacy");
        }
    }

    /**
     * Parse the {@code application} XML tree at the current parse location in a
     * <em>split APK</em> manifest.