Skip to content

Commit b3d4f6c

Browse files
committed
Log the actual wallet file version
The actual wallet file version is the minversion record, not the version record.
1 parent c88e87c commit b3d4f6c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/wallet/walletdb.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,8 @@ DBErrors WalletBatch::LoadWallet(CWallet* pwallet)
509509
int last_client = CLIENT_VERSION;
510510
ReadVersion(last_client);
511511

512-
pwallet->WalletLogPrintf("nFileVersion = %d\n", last_client);
512+
int wallet_version = pwallet->GetVersion();
513+
pwallet->WalletLogPrintf("Wallet File Version = %d\n", wallet_version > 0 ? wallet_version : last_client);
513514

514515
pwallet->WalletLogPrintf("Keys: %u plaintext, %u encrypted, %u w/ metadata, %u total. Unknown wallet records: %u\n",
515516
wss.nKeys, wss.nCKeys, wss.nKeyMeta, wss.nKeys + wss.nCKeys, wss.m_unknown_records);

0 commit comments

Comments
 (0)