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

Commit 81c502bd authored by Mathieu Chartier's avatar Mathieu Chartier
Browse files

Make sure to return false for empty classpath

Previously, the binder call was returning true causing the test to
fail.

Test: adb shell data/nativetest/installd_dexopt_test/installd_dexopt_test
Bug: 118818285
Bug: 118777746

(cherry picked from commit e0d64a13)

Change-Id: I7306b3113ca14ed92dd1740c0d682c1e51c1e52a
parent a5517d71
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -2693,6 +2693,13 @@ static bool create_boot_image_profile_snapshot(const std::string& package_name,
        return false;
    }

    // Return false for empty class path since it may otherwise return true below if profiles is
    // empty.
    if (classpath.empty()) {
        PLOG(ERROR) << "Class path is empty";
        return false;
    }

    // Open and create the snapshot profile.
    unique_fd snapshot_fd = open_spnashot_profile(AID_SYSTEM, package_name, profile_name);