mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-12 00:27:53 +02:00
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