[bug]: sweep: data race on TxPublisher.currentHeight
morehouse opened this issue · 2 comments
TxPublisher.currentHeight
is not guarded by a mutex but is accessed from multiple goroutines:
- in the
monitor
goroutineLine 718 in e8a1d48
- from outside calls to
Broadcast
Line 376 in e8a1d48
Lines 544 to 545 in e8a1d48
Lines 1124 to 1126 in e8a1d48
Line 1181 in e8a1d48
- in the
handleFeeBumpTx
goroutineLines 856 to 857 in e8a1d48
Lines 864 to 865 in e8a1d48
Lines 1124 to 1126 in e8a1d48
Line 1181 in e8a1d48
Can prob throw in an https://pkg.go.dev/sync/atomic#Int32
Thanks for reporting! Also found this issue while fixing the itest flakes and have a local branch already - still needs more work, meanwhile will use atomic
to provide a temp fix.