Consider stale if HARD_RESET while connected

Was disconnecting when more than one HARD_RESET_SERVER was
received during negotiation.
This commit is contained in:
Davide De Rosa 2019-04-17 01:26:39 +02:00
parent 0c3a4235aa
commit 887e2ae55d

View File

@ -519,7 +519,7 @@ public class SessionProxy {
// deferStop(.shutdown, e)
// return
}
if (code == .hardResetServerV2) && (negotiationKey.state != .hardReset) {
if (code == .hardResetServerV2) && (negotiationKey.controlState == .connected) {
deferStop(.shutdown, SessionError.staleSession)
return
} else if (code == .softResetV1) && (negotiationKey.state != .softReset) {