Open
Description
Originally posted by @darosior in bitcoin/bitcoin#32345 (comment)
I tested this PR by rebasing #29409 on top of it and running my (updated) core_bdk_wallet
against it.
I found that bitcoin-node
will (still) segfault if i try to stop it while the client is running. The steps i followed were to 1) start bitcoin-node
2) start my PoC which will connect to it and stall with the open connection for 6 seconds 3) before the 6 seconds have elapsed, stop the bitcoin-node
process (in this specific case by sending it a SIGINT
). Here are the logs of the bitcoin-node
process:
Click for `bitcoin-node` logs before segfault
[...]
2025-05-20T18:44:44Z init message: Starting network threads…
2025-05-20T18:44:44Z DNS seeding disabled
2025-05-20T18:44:44Z init message: Done loading
2025-05-20T18:44:44Z initload thread start
2025-05-20T18:44:44Z msghand thread start
2025-05-20T18:44:44Z Loading 0 mempool transactions from file...
2025-05-20T18:44:44Z Imported mempool transactions from file: 0 succeeded, 0 failed, 0 expired, 0 already there, 0 waiting for initial broadcast
2025-05-20T18:44:44Z opencon thread start
2025-05-20T18:44:44Z addcon thread start
2025-05-20T18:44:44Z net thread start
2025-05-20T18:44:44Z initload thread exit
2025-05-20T18:44:44Z New manual v2 peer connected: version: 70016, blocks=113, peer=0
2025-05-20T18:44:44Z Synchronizing blockheaders, height: 113 (~0.47%)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #1 Init.construct$Params ()
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #1 Init.construct$Results (threadMap = <external capability>)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #2 Init.makeChain$Params (context = (thread = <external capability>))
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #2 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #2 Init.makeChain$Results (result = <external capability>)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #3 Chain.initMessage$Params (context = (thread = <external capability>), message = "Oxydation of the Bitcoin Core wallet in progress..")
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #3 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z init message: Oxydation of the Bitcoin Core wallet in progress..
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #3 Chain.initMessage$Results ()
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #4 Chain.showProgress$Params (context = (thread = <external capability>), title = "BDK Core startup", progress = 1, resumePossible = false)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #4 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #4 Chain.showProgress$Results ()
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #5 Chain.getHeight$Params (context = (thread = <external capability>))
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #5 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #5 Chain.getHeight$Results (result = 113, hasResult = true)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #6 Chain.getBlockHash$Params (context = (thread = <external capability>), height = 113)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #6 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #6 Chain.getBlockHash$Results (result = "H\\3678\\307#\\020|\\020\\017\\340\\2469\\330\\356\\335\\277\\341dOB{\\220\\327\\354[\\361\\036\\233\\301\\035DD")
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #7 Chain.showProgress$Params (context = (thread = <external capability>), title = "BDK Core startup", progress = 100, resumePossible = true)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #7 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #7 Chain.showProgress$Results ()
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server recv request #8 Chain.handleNotifications$Params (context = (thread = <external capability>), notifications = <external capability>)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server post request #8 {bitcoin-node-948798/b-capnp-loop-948823 (from )}
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server send response #8 Chain.handleNotifications$Results (result = <external capability>)
2025-05-20T18:44:45Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server destroy N2mp11ProxyServerIN3ipc5capnp8messages7HandlerEEE
^C2025-05-20T18:44:47Z Shutdown: In progress...
2025-05-20T18:44:47Z addcon thread exit
2025-05-20T18:44:47Z opencon thread exit
2025-05-20T18:44:47Z net thread exit
2025-05-20T18:44:47Z msghand thread exit
2025-05-20T18:44:47Z scheduler thread exit
2025-05-20T18:44:47Z Writing 0 mempool transactions to file...
2025-05-20T18:44:47Z Writing 0 unbroadcast transactions to file.
2025-05-20T18:44:47Z Dumped mempool: 0.000s to copy, 0.003s to dump, 27 bytes dumped to file
2025-05-20T18:44:47Z Flushed fee estimates to fee_estimates.dat.
2025-05-20T18:44:47Z [ipc] {bitcoin-node-948798/b-shutoff-948798} IPC client first request from current thread, constructing waiter
2025-05-20T18:44:47Z [ipc] {bitcoin-node-948798/b-shutoff-948798} IPC client send ChainNotifications.chainStateFlushed$Params (context = (thread = <external capability>, callbackThread = <external capability>), role = 0, locator = "\\200\\021\\001\\000\\022H\\3678\\307#\\020|\\020\\017\\340\\2469\\330\\356\\335\\277\\341dOB{\\220\\327\\354[\\361\\036\\233\\301\\035DD\\tGm\\237]YbZDV9\\254\\252f\\205\\001\\323K\\375!\\340\\t\\367\\375\\346\\264W\\207\\000\\2101\\035:\\314\\233\\246\\275\\207\\v\\\\\\\\\\343\\202\\026\\274\\037\\213\\314\\303V\\2116<*+\\352\\255\\026\\204M\\332\\340\\nT\\306\\360Pa\\304\\002\\024\\356\\247\\220\\263\\257l\\230\\350\\362\\027Yl\\300\\316lk\\232\\f\\333\\235,\\234\\336\\204+JE\\263>\\237\\177\\305z\\017\\252\\311@\\341e\\026\\300dk\\305\\212V\\334\\377\\004cb\\217p\\n\\307w\\0046\\2261|\\024\\\\N\\336\\223G\\263~n\\271\\256\\264\\346\\227\\301\\032\\301\\030\\bw\\241Z.\\302\\261\\027 \\005\\374B\\357R\\231\\237Ct\\324\\232I\\322\\370\\303T\\253\\205\\354\\233\\337\\031C\\3215O\\3746\\016\\360b &\\300\\201\\244U\\221\\306 Pql+c\\212\\2524\\314a\\t\\216\\275=\\230b\\207ouv[\\365(\\3...
2025-05-20T18:44:47Z [ipc] {bitcoin-node-948798/b-shutoff-948798} IPC client recv ChainNotifications.chainStateFlushed$Results ()
2025-05-20T18:44:47Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server destroy N2mp11ProxyServerIN3ipc5capnp8messages5ChainEEE
2025-05-20T18:44:47Z [ipc] {bitcoin-node-948798/b-capnp-loop-948800} IPC server destroy N2mp11ProxyServerIN3ipc5capnp8messages4InitEEE
Segmentation fault
Metadata
Metadata
Assignees
Labels
No labels