refactor: pull libbitcoin_server code out of wallet code 3/N#5743
refactor: pull libbitcoin_server code out of wallet code 3/N#5743PastaPastaPasta merged 9 commits intodashpay:developfrom
Conversation
71292ec to
3f77c9d
Compare
3f77c9d to
c234a00
Compare
|
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp
index 206ff59f54..81ac0b7edb 100644
--- a/src/wallet/wallet.cpp
+++ b/src/wallet/wallet.cpp
@@ -5517,7 +5517,7 @@ bool CWallet::GenerateNewHDChainEncrypted(const SecureString& secureMnemonic, co
bool CWallet::ShutdownRequested()
{
- return chain().shutdownRequested();
+ return HaveChain() && chain().shutdownRequested();
}
void CWallet::UpdateProgress(const std::string& title, int nProgress) |
c234a00 to
a2ca4a1
Compare
|
This pull request has conflicts, please rebase. |
a2ca4a1 to
845d5d5
Compare
|
ping @PastaPastaPasta |
src/wallet/wallet.h
Outdated
There was a problem hiding this comment.
it'd be nice to use string_view here but I think ShowProgress probably wants a std::string
There was a problem hiding this comment.
yes, ShowProgress indeed uses std::string even in the latest version of bitcoin core:
boost::signals2::signal<void (const std::string &title, int nProgress)> ShowProgress;
The strMsg that is used in scriptpubkeyman.cpp is also std::string, so, using string_view will add a new allocation here, I will keep it as it is.
src/interfaces/chain.h
Outdated
There was a problem hiding this comment.
please rework this comment; doesn't make sense
src/wallet/wallet.cpp
Outdated
There was a problem hiding this comment.
refactor to use std::all_of, std::any_of or std::none_of ?
There was a problem hiding this comment.
that's not new code, I just moved a function to a new place. Anyway, I provided a refactoring in an extra commit
845d5d5 to
2e0bd50
Compare
PastaPastaPasta
left a comment
There was a problem hiding this comment.
utACK for merging via merge commit
…global variable in wallet's code
2e0bd50 to
e3d9327
Compare
Issue being fixed or feature implemented
Wallet library should not depends on server code (libbitcoin_server).
Untie this library will help to finish backport bitcoin#15639 and will unblock multiprocess: bitcoin#18677
Prior work:
What was done?
havePrunedfrom interface instead directfPruneuiInterfacefShutdownfrom scriptpubkeymanllmq::quorumInstantSendManager/llmq::chainLocksHandlerare wrapper in interfacedeterministicMNManagerfrom wallet codeHow Has This Been Tested?
Amount of linkage errors is decreased from 196 to 141 if
libbitcoin_serveris excluded during linkage:Breaking Changes
N/A
Checklist: