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

Commit f6d4e74b authored by Yifan Hong's avatar Yifan Hong
Browse files

libsnapshot: Re-expose InitiateMerge and ProcessUpdateState

These functions are used directly in update_engine now that
it is responsible for initiating the merge. update_engine has
its own message loop, so WaitForMerge / InitiateMergeAndWait
becomes useless and are deprecated.

Bug: 147696014
Test: compiles

Change-Id: Id8cb14f5f18b4893e2fc3d0d2b374a867a220e6f
Merged-In: Id8cb14f5f18b4893e2fc3d0d2b374a867a220e6f
parent 83fe0a35
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -140,7 +140,6 @@ class SnapshotManager final {
    // Before calling this function, all snapshots must be mapped.
    bool FinishedSnapshotWrites();

  private:
    // Initiate a merge on all snapshot devices. This should only be used after an
    // update has been marked successful after booting.
    bool InitiateMerge();
@@ -172,7 +171,6 @@ class SnapshotManager final {
    UpdateState ProcessUpdateState(const std::function<void()>& callback = {},
                                   const std::function<bool()>& before_cancel = {});

  public:
    // Initiate the merge if necessary, then wait for the merge to finish.
    // See InitiateMerge() and ProcessUpdateState() for details.
    // Returns: