summaryrefslogtreecommitdiffstats
path: root/scripts/remote/ratp.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/remote/ratp.py')
-rw-r--r--scripts/remote/ratp.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/remote/ratp.py b/scripts/remote/ratp.py
index 7972d31f2f..44f3e2f40a 100644
--- a/scripts/remote/ratp.py
+++ b/scripts/remote/ratp.py
@@ -721,7 +721,7 @@ class RatpConnection(object):
def close(self, timeout=1.0):
deadline = monotonic() + timeout
logging.info("CLOSE")
- if self._state == RatpState.established:
+ if self._state == RatpState.established or self._state == RatpState.syn_received:
fin = RatpPacket(flags='FA')
fin.c_sn = (self._s_sn + 1) % 2
fin.c_an = (self._r_sn + 1) % 2