mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-130718 Updater leaves behind a broken installation if it fails to open a file on Windows
This commit is contained in:
@@ -51,7 +51,9 @@ public class DeleteAction extends PatchAction {
|
||||
}
|
||||
|
||||
protected void doRevert(File toFile, File backupFile) throws IOException {
|
||||
Utils.delete(toFile); // make sure there is no directory remained on this path (may remain from previous 'create' actions
|
||||
Utils.copy(backupFile, toFile);
|
||||
if (!toFile.exists() || isModified(toFile)) {
|
||||
Utils.delete(toFile); // make sure there is no directory remained on this path (may remain from previous 'create' actions
|
||||
Utils.copy(backupFile, toFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user