mirror of
https://github.com/kvazar-network/kevacoin.git
synced 2025-01-11 15:48:05 +00:00
Merge pull request #409 from TheBlueMatt/master
Fix crashes when a wallet is locked and GetReservedKey() is called
This commit is contained in:
commit
60d2f8662c
@ -1320,7 +1320,10 @@ vector<unsigned char> CReserveKey::GetReservedKey()
|
||||
{
|
||||
CKeyPool keypool;
|
||||
pwallet->ReserveKeyFromKeyPool(nIndex, keypool);
|
||||
if (nIndex != -1)
|
||||
vchPubKey = keypool.vchPubKey;
|
||||
else
|
||||
vchPubKey = vchDefaultKey;
|
||||
}
|
||||
assert(!vchPubKey.empty());
|
||||
return vchPubKey;
|
||||
|
Loading…
Reference in New Issue
Block a user