Commit cac2012
committed
lightningd: don't crash if replaying blocks for onchaind during shutdown.
```
lightningd-1 2024-11-15T04:06:47.660Z UNUSUAL lightningd: JSON-RPC shutdown
lightningd-1 2024-11-15T04:06:47.665Z DEBUG lightningd: io_break: start_json_stream
lightningd-1 2024-11-15T04:06:47.666Z DEBUG lightningd: io_loop_with_timers: main
lightningd-1 2024-11-15T04:06:47.672Z DEBUG connectd: REPLY WIRE_CONNECTD_START_SHUTDOWN_REPLY with 0 fds
lightningd-1 2024-11-15T04:06:47.674Z DEBUG lightningd: io_break: connectd_start_shutdown_reply
lightningd-1 2024-11-15T04:06:47.680Z DEBUG 022d223620a359a47ff7f7ac447c85c46c923da53389221a0054c11c1e3ca31d59-onchaind-chan#1: Status closed, but not exited. Killing
lightningd-1 2024-11-15T04:06:47.715Z **BROKEN** lightningd: FATAL SIGNAL 11 (version e627dbf-modded)
------------------------------- Valgrind errors --------------------------------
Valgrind error file: valgrind-errors.43310
==43310== Invalid read of size 8
==43310== at 0x1B5717: subd_send_msg (subd.c:842)
==43310== by 0x17563A: onchain_tx_depth (onchain_control.c:177)
==43310== by 0x175E92: replay_block (onchain_control.c:391)
==43310== by 0x12E30C: getrawblockbyheight_callback (bitcoind.c:506)
==43310== by 0x1A5AC0: plugin_response_handle (plugin.c:663)
==43310== by 0x1A5D3C: plugin_read_json_one (plugin.c:775)
==43310== by 0x1A5F79: plugin_read_json (plugin.c:826)
==43310== by 0x38F320: next_plan (io.c:60)
==43310== by 0x38FF76: do_plan (io.c:422)
==43310== by 0x38FFDD: io_ready (io.c:439)
==43310== by 0x392411: io_loop (poll.c:455)
==43310== by 0x1AB630: shutdown_plugins (plugin.c:2588)
==43310== Address 0x58 is not stack'd, malloc'd or (recently) free'd
==43310==
```
Signed-off-by: Rusty Russell <[email protected]>1 parent 102e223 commit cac2012
1 file changed
+4
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
383 | 383 | | |
384 | 384 | | |
385 | 385 | | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
386 | 390 | | |
387 | 391 | | |
388 | 392 | | |
| |||
0 commit comments