MarcoFalke
commented at 9:18 PM on August 19, 2019:
member
CreateWalletFromFile has a bunch of issues:
walletFile refers to freed memory and will thus corrupt the debug.log and/or crash the node if read
WalletParameterInteraction was moved to CreateWalletFromFile and WalletInit::ParameterInteraction without updating the documentation
loadwallet and createwallet will not pass up errors from CreateWalletFromFile to the RPC caller
Fix each of those issues in a separate commit.
MarcoFalke force-pushed on Aug 19, 2019
DrahtBot
commented at 9:48 PM on August 19, 2019:
member
<!--e57a25ab6845829454e8d69fc972939a-->
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
<!--174a7506f384e20aa4161008e828411d-->
Conflicts
Reviewers, this pull request conflicts with the following ones:
#16341 (Introduce ScriptPubKeyMan interface and use it for key and script management (aka wallet boxes) by achow101)
#16261 (gui: Refactor OpenWalletActivity by promag)
#15450 (gui: Create wallet menu option by achow101)
#10102 ([experimental] Multiprocess bitcoin by ryanofsky)
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.
practicalswift
commented at 9:52 PM on August 19, 2019:
contributor
Concept ACK -- very good find!
The problem was introduced in #15491 which was merged into master on March 18, 2019.
@MarcoFalke While checking this PR I stumbled upon what seems to be another lifetime issue in wallet.cpp (introduced in #14941 which was merged into master on January 15, 2019):
I guess we could make use of more static analysis to help us catch cases like this before merge :-)
DrahtBot added the label Tests on Aug 19, 2019
DrahtBot added the label Wallet on Aug 19, 2019
MarcoFalke removed the label Tests on Aug 19, 2019
MarcoFalke added this to the milestone 0.19.0 on Aug 19, 2019
MarcoFalke
commented at 11:05 PM on August 19, 2019:
member
@practicalswift I think it would be better to open a new issue for the lifetime issue you mention. And either explain why it is a lifetime issue or even better, include a test case that fails on current master.
practicalswift
commented at 10:28 AM on August 20, 2019:
contributor
I think it would be better to open a new issue for the lifetime issue you mention.
And either explain why it is a lifetime issue or even better, include a test case that fails on current master.
Constructing a test case that fails on current master will be tricky since lifetime issues are typically not handled consistently across C++ compiler implementations (or even across optimisation levels for the same implementation), but explaining is easy:
After delete wallet; the pointer is invalid and shouldn't be used like in the call g_unloading_wallet_set.erase(wallet) :-)
ariard
commented at 2:19 PM on August 20, 2019:
member
ACK6f51ece, reviewed code and tests pass, maybe segfault fix could be more elaborated on the manual process to trigger crash in its message commit.
MarcoFalke force-pushed on Aug 20, 2019
MarcoFalke force-pushed on Aug 20, 2019
MarcoFalke force-pushed on Aug 20, 2019
promag
commented at 6:15 PM on August 20, 2019:
member
Concept ACK.
MarcoFalke force-pushed on Aug 20, 2019
MarcoFalke
commented at 6:26 PM on August 20, 2019:
member
Split up the changes into separate commits and added a commit body with an explanation to each. Also, fixed an appveyor issue with / vs \ in paths.
MarcoFalke force-pushed on Aug 21, 2019
MarcoFalke force-pushed on Aug 22, 2019
laanwj referenced this in commit 6e431296da on Sep 3, 2019
wallet: Fix segmentation fault in CreateWalletFromFilefa6e1900d5
wallet: Fix documentation around WalletParameterInteractionfa420d2a70
wallet: Pass error from CreateWalletFromFile to RPC
Common errors and warnings should be translated when displayed in the
GUI, but not translated when displayed elsewhere. The wallet method
CreateWalletFromFile does not know its caller, so this commit changes it
to return a bilingual_str to the caller.
fad650db3f
test: Print both messages on failure in assert_raises_messagefa504deefa
MarcoFalke force-pushed on Sep 3, 2019
MarcoFalke
commented at 6:40 PM on September 3, 2019:
member
I will fix the GUI issue (LC_ALL=de_DE.UTF-8 XDG_SESSION_TYPE=x11 BITCOIND=bitcoin-qt ./test/functional/wallet_multiwallet.py does not pass) in a separate pull request and the daemon issue in #16796. Thanks for the input everyone.
MarcoFalke closed this on Sep 3, 2019
MarcoFalke deleted the branch on Sep 3, 2019
sidhujag referenced this in commit f32507a747 on Sep 3, 2019
This is a metadata mirror of the GitHub repository
bitcoin/bitcoin.
This site is not affiliated with GitHub.
Content is generated from a GitHub metadata backup.
generated: 2026-04-14 21:14 UTC
This site is hosted by @0xB10C More mirrored repositories can be found on mirror.b10c.me