Rusty Russell
07c4d39b75
memleak: fix double-free if we timeout.
... and then dualopend returns, and we access the fread leak_detect struct.
```
lightningd: FATAL SIGNAL 6 (version 065ca1e)
0x55ecd4be8145 send_backtrace
common/daemon.c:33
0x55ecd4be81f1 crashdump
common/daemon.c:46
0x7f200acab51f ???
./signal/../sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c:0
0x7f200acff828 __pthread_kill_implementation
./nptl/pthread_kill.c:44
0x7f200acff828 __pthread_kill_internal
./nptl/pthread_kill.c:80
0x7f200acff828 __GI___pthread_kill
./nptl/pthread_kill.c:91
0x7f200acab475 __GI_raise
../sysdeps/posix/raise.c:26
0x7f200ac917b6 __GI_abort
./stdlib/abort.c:79
0x55ecd4c6827f call_error
ccan/ccan/tal/tal.c:93
0x55ecd4c68470 check_bounds
ccan/ccan/tal/tal.c:165
0x55ecd4c684c2 to_tal_hdr
ccan/ccan/tal/tal.c:175
0x55ecd4c68eb8 tal_free
ccan/ccan/tal/tal.c:479
0x55ecd4b8bdd0 finish_report
lightningd/memdump.c:138
0x55ecd4b8c115 leak_detect_req_done
lightningd/memdump.c:201
0x55ecd4c68664 notify
ccan/ccan/tal/tal.c:237
0x55ecd4c68b9e del_tree
ccan/ccan/tal/tal.c:402
0x55ecd4c68bf3 del_tree
ccan/ccan/tal/tal.c:412
0x55ecd4c68bf3 del_tree
ccan/ccan/tal/tal.c:412
0x55ecd4c68f43 tal_free
ccan/ccan/tal/tal.c:486
0x55ecd4c5751f io_close
ccan/ccan/io/io.c:450
0x55ecd4bbce68 subd_shutdown_remaining
lightningd/subd.c:911
0x55ecd4b8724a shutdown_subdaemons
lightningd/lightningd.c:541
0x55ecd4b883cc main
lightningd/lightningd.c:1207
0x7f200ac92fcf __libc_start_call_main
../sysdeps/nptl/libc_start_call_main.h:58
0x7f200ac9307c __libc_start_main_impl
../csu/libc-start.c:409
0x55ecd4b5cc54 ???
```
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2022-03-23 13:20:12 +10:30
..
2022-03-23 13:20:12 +10:30
2021-10-28 15:51:38 +02:00
2022-03-05 15:03:34 +10:30
2021-10-15 12:09:36 +02:00
2022-03-05 15:03:34 +10:30
2021-09-17 09:43:22 +09:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2021-01-10 13:44:04 +01:00
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-01-20 15:24:06 +10:30
2022-03-05 15:12:12 +10:30
2022-02-07 13:02:09 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2021-12-06 10:05:39 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-03-11 16:42:45 +10:30
2022-02-08 11:15:52 +10:30
2021-12-15 12:24:54 +10:30
2021-09-17 09:43:22 +09:30
2021-12-30 14:36:55 +10:30
2021-12-28 04:42:42 +10:30
2021-12-06 10:05:39 +10:30
2020-09-08 09:42:00 +09:30
2022-03-22 18:45:41 +10:30
2020-09-08 09:42:00 +09:30
2022-03-05 15:03:34 +10:30
2019-05-31 17:57:10 +02:00
2021-12-06 10:05:39 +10:30
2020-08-11 08:39:24 +09:30
2022-03-05 15:03:34 +10:30
2021-11-30 13:34:44 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2021-12-06 10:05:39 +10:30
2021-09-17 09:43:22 +09:30
2022-03-05 15:03:34 +10:30
2022-03-05 15:03:34 +10:30
2022-03-10 10:22:29 +10:30
2022-03-23 13:20:12 +10:30
2022-03-10 09:40:09 +10:30
2022-03-05 15:12:12 +10:30
2021-12-28 04:42:42 +10:30
2022-03-05 15:03:34 +10:30
2022-03-10 10:22:29 +10:30
2021-12-28 04:42:42 +10:30
2022-02-08 11:15:52 +10:30
2021-12-01 05:44:28 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-03-11 16:42:45 +10:30
2021-09-17 09:43:22 +09:30
2022-03-23 13:20:12 +10:30
2022-02-08 11:15:52 +10:30
2022-03-23 13:20:12 +10:30
2022-03-23 13:20:12 +10:30
2022-02-08 11:15:52 +10:30
2022-02-08 11:15:52 +10:30
2022-03-23 13:20:12 +10:30
2022-02-08 11:15:52 +10:30
2022-02-08 11:15:52 +10:30
2021-12-06 10:05:39 +10:30
2021-06-25 09:49:33 +09:30
2022-03-05 15:03:34 +10:30
2021-09-17 09:43:22 +09:30
2021-12-14 09:33:10 +10:30
2021-12-14 09:33:10 +10:30
2022-03-23 13:20:12 +10:30
2021-06-16 10:29:17 +09:30
2021-12-06 10:05:39 +10:30
2022-03-10 09:40:09 +10:30
2022-03-10 09:40:09 +10:30
2021-12-06 10:05:39 +10:30
2021-10-15 12:09:36 +02:00