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

Commit 0e9b53d8 authored by Mathieu Chartier's avatar Mathieu Chartier Committed by android-build-merger
Browse files

Unlink app image if copy fails for A/B OTA

am: a029c072

Change-Id: I06074c8c2f9ae317e607326b37c216a1ee2fd867
parents afc38fe2 a029c072
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -2186,6 +2186,9 @@ int move_ab(const char* apk_path, const char* instruction_set, const char* oat_d
        bool art_success = true;
        if (!a_image_path.empty()) {
            art_success = move_ab_path(b_image_path, a_image_path);
            if (!art_success) {
                unlink(a_image_path.c_str());
            }
        }

        success = art_success || kIgnoreAppImageFailure;