mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-24 01:24:26 +01:00
lightningd: display all addresses in listnodes.
We kept overwriting the first one on marshalling, so any following addresses were junk. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
584ee26200
commit
c5b5f74965
@@ -27,7 +27,7 @@ struct gossip_getnodes_entry *fromwire_gossip_getnodes_entry(const tal_t *ctx,
|
||||
entry->addresses = tal_arr(entry, struct wireaddr, numaddresses);
|
||||
for (i=0; i<numaddresses; i++) {
|
||||
/* Gossipd doesn't hand us addresses we can't understand. */
|
||||
if (!fromwire_wireaddr(pptr, max, entry->addresses)) {
|
||||
if (!fromwire_wireaddr(pptr, max, &entry->addresses[i])) {
|
||||
fromwire_fail(pptr, max);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user