p2p/discv5: add deprecation warning and remove unused code (#20367)
* p2p/discv5: add deprecation warning and remove unused code * p2p/discv5: remove unused variables
This commit is contained in:
committed by
Péter Szilágyi
parent
0abcf03fde
commit
fdff182f11
@ -77,14 +77,6 @@ type Network struct {
|
||||
nursery []*Node
|
||||
nodes map[NodeID]*Node // tracks active nodes with state != known
|
||||
timeoutTimers map[timeoutEvent]*time.Timer
|
||||
|
||||
// Revalidation queues.
|
||||
// Nodes put on these queues will be pinged eventually.
|
||||
slowRevalidateQueue []*Node
|
||||
fastRevalidateQueue []*Node
|
||||
|
||||
// Buffers for state transition.
|
||||
sendBuf []*ingressPacket
|
||||
}
|
||||
|
||||
// transport is implemented by the UDP transport.
|
||||
@ -104,10 +96,9 @@ type transport interface {
|
||||
}
|
||||
|
||||
type findnodeQuery struct {
|
||||
remote *Node
|
||||
target common.Hash
|
||||
reply chan<- []*Node
|
||||
nresults int // counter for received nodes
|
||||
remote *Node
|
||||
target common.Hash
|
||||
reply chan<- []*Node
|
||||
}
|
||||
|
||||
type topicRegisterReq struct {
|
||||
@ -650,10 +641,10 @@ loop:
|
||||
if net.conn != nil {
|
||||
net.conn.Close()
|
||||
}
|
||||
if refreshDone != nil {
|
||||
// TODO: wait for pending refresh.
|
||||
//<-refreshResults
|
||||
}
|
||||
// TODO: wait for pending refresh.
|
||||
// if refreshDone != nil {
|
||||
// <-refreshResults
|
||||
// }
|
||||
// Cancel all pending timeouts.
|
||||
for _, timer := range net.timeoutTimers {
|
||||
timer.Stop()
|
||||
|
Reference in New Issue
Block a user