mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 01:43:36 +01:00
c755dfdfc9
This code was trying to check that the address type is not one of the ADDR_TYPE_TOR* types, but the is_toraddr() function checks a domain name! The cast should have been a clue that this was wrong! Anyway, wireaddr_to_addrinfo() aborts on these cases already, so the asserts here are superfluous. Found in unrelated CI run: ``` Valgrind error file: valgrind-errors.20610 ==20610== Conditional jump or move depends on uninitialised value(s) ==20610== at 0x484ED28: strlen (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so) ==20610== by 0x138FA3: is_toraddr (wireaddr.c:344) ==20610== by 0x11499B: conn_init (connectd.c:729) ==20610== by 0x28FD73: next_plan (io.c:59) ==20610== by 0x28FF94: io_new_conn_ (io.c:116) ==20610== by 0x11531B: try_connect_one_addr (connectd.c:927) ==20610== by 0x1182A8: try_connect_peer (connectd.c:1781) ==20610== by 0x11834E: connect_to_peer (connectd.c:1797) ==20610== by 0x119241: recv_req (connectd.c:2074) ==20610== by 0x12836F: handle_read (daemon_conn.c:35) ==20610== by 0x28FD73: next_plan (io.c:59) ==20610== by 0x2909A8: do_plan (io.c:407) ==20610== ``` Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> |
||
---|---|---|
.. | ||
test | ||
connectd_gossipd_wire.csv | ||
connectd_wire.csv | ||
connectd.c | ||
connectd.h | ||
gossip_rcvd_filter.c | ||
gossip_rcvd_filter.h | ||
gossip_store.c | ||
gossip_store.h | ||
handshake.c | ||
handshake.h | ||
Makefile | ||
multiplex.c | ||
multiplex.h | ||
netaddress.c | ||
netaddress.h | ||
onion_message.c | ||
onion_message.h | ||
peer_exchange_initmsg.c | ||
peer_exchange_initmsg.h | ||
sha1.c | ||
sha1.h | ||
tor_autoservice.c | ||
tor_autoservice.h | ||
tor.c | ||
tor.h | ||
websocketd.c |