Always check return values of TxnBegin() and TxnCommit()
This commit is contained in:
@@ -242,7 +242,8 @@ bool CWallet::EncryptWallet(const SecureString& strWalletPassphrase)
|
||||
if (fFileBacked)
|
||||
{
|
||||
pwalletdbEncryption = new CWalletDB(strWalletFile);
|
||||
pwalletdbEncryption->TxnBegin();
|
||||
if (!pwalletdbEncryption->TxnBegin())
|
||||
return false;
|
||||
pwalletdbEncryption->WriteMasterKey(nMasterKeyMaxID, kMasterKey);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user