Skip to content

Commit 80d666b

Browse files
endothermicdevrustyrussell
authored andcommitted
gossipd: drive-by correction of new channel announcement evaluation
According to the description, we should be checking the existence of a channel update on the other side here. Changelog-None
1 parent b327bd3 commit 80d666b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

gossipd/gossmap_manage.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -618,7 +618,7 @@ void gossmap_manage_handle_get_txout_reply(struct gossmap_manage *gm, const u8 *
618618

619619
pca = map_del(&gm->pending_ann_map, scid);
620620
if (!pca) {
621-
/* If we looking specifically for this, we no longer
621+
/* If we were looking specifically for this, we no longer
622622
* are (but don't penalize sender: we don't know if it was
623623
* good or bad). */
624624
remove_unknown_scid(gm->daemon->seeker, &scid, true);
@@ -703,7 +703,7 @@ void gossmap_manage_handle_get_txout_reply(struct gossmap_manage *gm, const u8 *
703703
txout_failures_add(gm->txf, scid);
704704
out:
705705
tal_free(pca);
706-
/* If we looking specifically for this, we no longer are. */
706+
/* If we were looking specifically for this, we no longer are. */
707707
remove_unknown_scid(gm->daemon->seeker, &scid, false);
708708
}
709709

@@ -773,7 +773,7 @@ static const char *process_channel_update(const tal_t *ctx,
773773
} else {
774774
/* Is this the first update in either direction? If so,
775775
* rewrite channel_announcement so timestamp is correct. */
776-
if (!gossmap_chan_set(chan, dir))
776+
if (!gossmap_chan_set(chan, !dir))
777777
gossip_store_set_timestamp(gm->daemon->gs, chan->cann_off, timestamp);
778778
}
779779

0 commit comments

Comments
 (0)