AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 15 Bitcoin

common: fix `bad cupdates` count in gossmap.c

Public commit record

What the developer wrote

Authored by Rusty Russell

68/100 · Adequate
common: fix `bad cupdates` count in gossmap.c

I noticed this in the logs:

```
lightningd-1 2026-01-28T00:27:37.504Z DEBUG gossipd: gossip_store: Read 59428/118856/0/0 cannounce/cupdate/nannounce/delete from store in 45521871 bytes, now 45521849 bytes (populated=true)
lightningd-1 2026-01-28T00:27:37.504Z DEBUG gossipd: Got 118856 bad cupdates, ignoring them (expected on mainnet)
```

That's weird, and turns out it counting good updates, not bad ones!

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
The short version

What changed, and why it matters

This is a one-line logging fix. The code was counting successful channel updates as 'bad' channel updates in a debug log message. The fix flips the boolean so the counter increments only when an update actually fails. It does not change any network behavior, validation rules, or security logic.

Recommended action

No security action needed. Treat as a normal bugfix/logging correction.

Security signals we found

No strong security signals were identified.

Risk score

Why this scored 15/100

Our methodology →
Potential impact 0/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 0/15
Confidence 10/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.