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

Commit 5a6ab7d8 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "snapshotctl: Initialize snapshot pointer when reverting snapshots" into main

parents 5c8ebb25 e69b2d42
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -105,7 +105,7 @@ class MapSnapshots {
    bool FinishSnapshotWrites();
    bool UnmapCowImagePath(std::string& name);
    bool DeleteSnapshots();
    bool CleanupSnapshot() { return sm_->PrepareDeviceToBootWithoutSnapshot(); }
    bool CleanupSnapshot();
    bool BeginUpdate();
    bool ApplyUpdate();

@@ -495,6 +495,11 @@ bool MapSnapshots::UnmapCowImagePath(std::string& name) {
    return sm_->UnmapCowImage(name);
}

bool MapSnapshots::CleanupSnapshot() {
    sm_ = SnapshotManager::New();
    return sm_->PrepareDeviceToBootWithoutSnapshot();
}

bool MapSnapshots::DeleteSnapshots() {
    sm_ = SnapshotManager::New();
    lock_ = sm_->LockExclusive();