Merge "Clear BCB if space allocation failed"

This commit is contained in:
Treehugger Robot
2022-02-24 18:58:21 +00:00
committed by Gerrit Code Review

View File

@@ -674,10 +674,12 @@ public class RecoverySystem {
}
try {
if (!rs.allocateSpaceForUpdate(packageFile)) {
rs.clearBcb();
throw new IOException("Failed to allocate space for update "
+ packageFile.getAbsolutePath());
}
} catch (RemoteException e) {
rs.clearBcb();
e.rethrowAsRuntimeException();
}