diff options
author | MacroFake <falke.marco@gmail.com> | 2022-06-30 18:38:11 +0200 |
---|---|---|
committer | MacroFake <falke.marco@gmail.com> | 2022-06-30 18:38:20 +0200 |
commit | c892cb7d8d8de0d4e1d414346ae4bad016f61917 (patch) | |
tree | 227393c1ff0c66ffd0354c19718aa22029332dfa /src/qt/bitcoin.h | |
parent | 5d68d6840d9ca82754dc66e96d1cf1444b830c9d (diff) | |
parent | c318211ddd48d44dd81dded553afeee3bc41c89e (diff) |
Merge bitcoin/bitcoin#25383: wallet: don't read db every time that a new 'WalletBatch' is created
c318211ddd48d44dd81dded553afeee3bc41c89e walletdb: fix last client version update (furszy)
bda8ebe608e6572eaaf40cd28dab6954241c9b0d wallet: don't read db every time that a new WalletBatch is created (furszy)
Pull request description:
Found it while was working on #25297.
We are performing a db read operation every time that a new `WalletBatch` is created, inside the constructor, just to check if the client version field is inside the db or not.
As the client version field does not change in the entire db lifecycle, this operation can be done only once: The first time that the db is accessed/opened and the client version value can be cached.
ACKs for top commit:
achow101:
ACK c318211ddd48d44dd81dded553afeee3bc41c89e
w0xlt:
reACK https://github.com/bitcoin/bitcoin/pull/25383/commits/c318211ddd48d44dd81dded553afeee3bc41c89e
Tree-SHA512: 7fb780c656e169e8eb21e7212242494a647f6506d6da2cca828703713d440d29c82bec9e7d2c410f37b49361226ccd80846d3eeb8168383d0c2a11d85d73bee2
Diffstat (limited to 'src/qt/bitcoin.h')
0 files changed, 0 insertions, 0 deletions