les: les/4 minimalistic version (#21909)

* les: allow tx unindexing in les/4 light server mode

* les: minor fixes

* les: more small fixes

* les: add meaningful constants for recentTxIndex handshake field
This commit is contained in:
Felföldi Zsolt
2020-12-15 20:12:14 +01:00
committed by GitHub
parent 8cde2966af
commit c7f2536735
4 changed files with 40 additions and 6 deletions

View File

@ -488,7 +488,7 @@ func (r *TxStatusRequest) GetCost(peer *serverPeer) uint64 {
// CanSend tells if a certain peer is suitable for serving the given request
func (r *TxStatusRequest) CanSend(peer *serverPeer) bool {
return peer.version >= lpv2
return peer.serveTxLookup
}
// Request sends an ODR request to the LES network (implementation of LesOdrRequest)