Fix init segfault where InitLoadWallet() calls ATMP before genesis #8928
pull TheBlueMatt wants to merge 1 commits into bitcoin:master from TheBlueMatt:2016-10-fix-segfault changing 2 files +7 −2-
TheBlueMatt commented at 5:21 pm on October 15, 2016: memberI honestly have no idea how the wallet.py tests are passing for anyone, but they reliably cause segfault here for me.
-
Fix init segfault where InitLoadWallet() calls ATMP before genesis 37aefff5fc
-
MarcoFalke commented at 10:18 am on October 16, 2016: member
utACK 37aefff5fcf7169a1b07ff8939850f630640f7e7
Edit: Indeed interesting that this does not fail on trusty.
Tested ACK 37aefff, otherwise.
-
MarcoFalke added the label Wallet on Oct 16, 2016
-
in src/init.cpp: in 37aefff5fc
1487@@ -1488,6 +1488,13 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) 1488 uiInterface.NotifyBlockTip.disconnect(BlockNotifyGenesisWait); 1489 } 1490 1491+#ifdef ENABLE_WALLET 1492+ // Add wallet transactions that aren't already in a block to mempool 1493+ // Do this here as mempool requires genesis block to be loaded 1494+ if (pwalletMain) 1495+ pwalletMain->ReacceptWalletTransactions();
jonasschnelli commented at 6:49 am on October 17, 2016:Meh on extending the usage ofpwalletMain
ininit.cpp
. If this is really necessary, can’t we pack it “behind”CWallet
?
jonasschnelli commented at 6:51 am on October 17, 2016:Or what about moving down theif (!CWallet::InitLoadWallet())
from L1426 to the part?
laanwj commented at 4:12 pm on October 19, 2016:@jonasschnelli we can do this laterin src/init.cpp: in 37aefff5fc
1487@@ -1488,6 +1488,13 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) 1488 uiInterface.NotifyBlockTip.disconnect(BlockNotifyGenesisWait); 1489 } 1490 1491+#ifdef ENABLE_WALLET
laanwj commented at 9:21 pm on October 18, 2016:It’s unfortunate that this has to introduce a new#ifdef ENABLE_WALLET
here, and ref to pWalletMain. We’re trying to get rid of them to remove the circular dependency between_wallet
and_server
libs (#7965), and in the interest of multi-wallet support.
MarcoFalke commented at 9:08 am on October 19, 2016:It could be combined with the guard a few lines below, but this won’t solve the larger problem.
I think for a bugfix this is fine.
laanwj commented at 4:10 pm on October 19, 2016:Yes I agree, let’s merge this as it is a necessary bugfix, this can be improved later.laanwj commented at 9:23 pm on October 18, 2016: memberutACK otherwisejonasschnelli changes_requestedlaanwj merged this on Oct 19, 2016laanwj closed this on Oct 19, 2016
laanwj referenced this in commit c587577356 on Oct 19, 2016codablock referenced this in commit f21b2ecc84 on Sep 19, 2017codablock referenced this in commit fdd0638161 on Jan 9, 2018andvgal referenced this in commit 8b885462a1 on Jan 6, 2019MarcoFalke locked this on Sep 8, 2021
github-metadata-mirror
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: 2024-11-27 06:12 UTC
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: 2024-11-27 06:12 UTC
This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me
More mirrored repositories can be found on mirror.b10c.me