Skip to content

Commit

Permalink
misc: clarifications from cdecker review.
Browse files Browse the repository at this point in the history
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
  • Loading branch information
rustyrussell committed Feb 7, 2022
1 parent 7530018 commit 73e325c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion connectd/multiplex.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ void multiplex_final_msg(struct peer *peer,
const u8 *final_msg TAKES);

/* Inject a message into the output stream. Unlike a raw msg_enqueue,
* this does io logging if required. */
* this does io logging. */
void inject_peer_msg(struct peer *peer, const u8 *msg TAKES);

void setup_peer_gossip_store(struct peer *peer,
Expand Down
6 changes: 6 additions & 0 deletions gossipd/gossip_generation.c
Original file line number Diff line number Diff line change
Expand Up @@ -821,6 +821,12 @@ void handle_used_local_channel_update(struct daemon *daemon, const u8 *msg)
&scid));
return;
}

/* This whole idea is racy: they might have used a *previous* update.
* But that's OK: the notification is an optimization to avoid
* broadcasting updates we never use (route flapping). In this case,
* we might broadcast a more recent update than the one we sent to a
* peer. */
local_channel_update_latest(daemon, chan);
}

Expand Down
2 changes: 1 addition & 1 deletion gossipd/gossipd.c
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ static void handle_recv_gossip(struct daemon *daemon, const u8 *outermsg)

peer = find_peer(daemon, &id);
if (!peer) {
status_broken("connectd sent gossip msg %s for unknown peer %s",
status_broken("connectd sent gossip msg %s from unknown peer %s",
peer_wire_name(fromwire_peektype(msg)),
type_to_string(tmpctx, struct node_id, &id));
return;
Expand Down

0 comments on commit 73e325c

Please sign in to comment.