diff --git a/core/src/main/java/com/google/bitcoin/core/Wallet.java b/core/src/main/java/com/google/bitcoin/core/Wallet.java index e5b25de6..4761111d 100644 --- a/core/src/main/java/com/google/bitcoin/core/Wallet.java +++ b/core/src/main/java/com/google/bitcoin/core/Wallet.java @@ -531,7 +531,13 @@ public class Wallet implements Serializable, BlockChainListener, PeerFilterProvi } } - if (!success) log.error(toString()); + if (!success) { + try { + log.error(toString()); + } catch (RuntimeException x) { + log.error("Printing inconsistent wallet failed", x); + } + } return success; } finally { lock.unlock();