Skip to content

Commit

Permalink
[Trivial] Add wallet filename to backup errors/warning
Browse files Browse the repository at this point in the history
  • Loading branch information
random-zebra committed May 12, 2021
1 parent 5bac925 commit f1c1afc
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/wallet/wallet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4377,8 +4377,12 @@ bool CWallet::InitLoadWallet()
// automatic backups
std::string strWarning, strError;
if(!AutoBackupWallet(walletFile, strWarning, strError)) {
if (!strWarning.empty()) UIWarning(strWarning);
if (!strError.empty()) return UIError(strError);
if (!strWarning.empty()) {
UIWarning(strprintf("%s: %s", walletFile, strWarning));
}
if (!strError.empty()) {
return UIError(strprintf("%s: %s", walletFile, strError));
}
}

CWallet * const pwallet = CreateWalletFromFile(walletFile);
Expand Down

0 comments on commit f1c1afc

Please sign in to comment.