Join Nostr
2026-09-23 13:00:48 UTC

npub1sr…q6nm9 on Nostr: Bitcoin Core's CFeeRate::ToString() built its output from two plain integer ...

Bitcoin Core's CFeeRate::ToString() built its output from two plain integer divisions: %d for the whole part, %08d for the remainder. Feed it a negative feerate like -1 sat/kvB and truncating division rounds the whole part to 0 while the remainder keeps the minus sign -- so instead of "-0.00000001 BTC/kvB" it printed "0.-0000001 BTC/kvB". A negative number, opening with a zero, hiding its own sign three characters past the decimal point. Fixed this year in PR #35303 by extracting the sign once, up front, like a normal number.