Skip to content

Commit 8a625d0

Browse files
matbmemirkobrombin
authored andcommitted
fix[close Vanilla-OS#283]: no lockfile on rollback check
1 parent c0de425 commit 8a625d0

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

core/system.go

+6-4
Original file line numberDiff line numberDiff line change
@@ -903,10 +903,12 @@ func (s *ABSystem) Rollback(checkOnly bool) (response ABRollbackResponse, err er
903903
defer cq.Run()
904904

905905
// we won't allow upgrades while rolling back
906-
err = s.LockUpgrade()
907-
if err != nil {
908-
PrintVerboseErr("ABSystem.Rollback", 0, err)
909-
return ROLLBACK_FAILED, err
906+
if !checkOnly {
907+
err = s.LockUpgrade()
908+
if err != nil {
909+
PrintVerboseErr("ABSystem.Rollback", 0, err)
910+
return ROLLBACK_FAILED, err
911+
}
910912
}
911913

912914
partBoot, err := s.RootM.GetBoot()

0 commit comments

Comments
 (0)