go-ethereum/p2p/discover
Felix Lange 281dc4c209
p2p/discover: decouple nodeFeed from Table mutex in waitForNodes (#34898)
Fixes #34881

This fixes a hang in `Table.waitForNodes`. It is a replacement for PRs
#34890, #33665 which tried to fix the same issue in a different way.

- #34890 doesn't really fix the issue, just makes it less likely
- #33665 tries to fix it by moving the feed send outside of the lock

I created this PR because I want to keep the synchronous node feed
sending in `Table.nodeAdded`.

---------

Co-authored-by: Csaba Kiraly <csaba.kiraly@gmail.com>
2026-05-08 11:33:19 +02:00
..
v4wire
v5wire
common.go
lookup.go
metrics.go
node.go
ntp.go
table.go p2p/discover: decouple nodeFeed from Table mutex in waitForNodes (#34898) 2026-05-08 11:33:19 +02:00
table_reval.go
table_reval_test.go
table_test.go p2p/discover: decouple nodeFeed from Table mutex in waitForNodes (#34898) 2026-05-08 11:33:19 +02:00
table_util_test.go
v4_lookup_test.go
v4_udp.go
v4_udp_test.go
v5_talk.go
v5_udp.go
v5_udp_test.go