clean up protocol version for proxying
The proxy always checks the protocol version of a remote before talking to it in a version-specific way, so the protocol version in the ProxyParams is the client's protocol version. The remote will always be at the same or an older protocol version than the client. Note that in relayDATAFinish, when the client is at protocol version 0, the remote must thus be as well, and that's why its version is not checked in the case for that. With that clarified, it's evident that, in P2P.Http.State, there's no need to look at the proxied remote's protocol version at all.
This commit is contained in:
parent
de7730f51f
commit
ad025b8e5e
5 changed files with 17 additions and 23 deletions
|
@ -84,7 +84,7 @@ performProxy clientuuid servermode r = do
|
|||
, proxyUUID = Remote.uuid r
|
||||
, proxySelector = singleProxySelector remoteside
|
||||
, proxyConcurrencyConfig = concurrencyconfig
|
||||
, proxyProtocolVersion = protocolversion
|
||||
, proxyClientProtocolVersion = protocolversion
|
||||
}
|
||||
let runproxy othermsg' = proxy closer proxyparams
|
||||
othermsg' errhandler
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue