Wallet: try deleting the temp file in the finally block and print a warning if it succeeded.

Resolves issue 362.
This commit is contained in:
Mike Hearn
2013-03-30 17:35:36 +00:00
parent 301db707b1
commit 9201cba0cc

View File

@@ -415,6 +415,9 @@ public class Wallet implements Serializable, BlockChainListener {
if (stream != null) {
stream.close();
}
if (temp.delete()) {
log.warn("Deleted temp file after failed save.");
}
}
}