diff options
author | cliechti <cliechti@f19166aa-fa4f-0410-85c2-fa1106f25c8a> | 2014-07-31 15:29:34 +0000 |
---|---|---|
committer | cliechti <cliechti@f19166aa-fa4f-0410-85c2-fa1106f25c8a> | 2014-07-31 15:29:34 +0000 |
commit | c00ef647297d5706e533334eea28fcb00cc461db (patch) | |
tree | 46a77147558806126113d74f52809c5ebd87c2fb /serial | |
parent | b6986f97b2f0c8ac42c67698aa090d155b657ff6 (diff) | |
download | pyserial-c00ef647297d5706e533334eea28fcb00cc461db.tar.gz |
[Bug pyserial:166] RFC2217 connections always fail
git-svn-id: http://svn.code.sf.net/p/pyserial/code/trunk/pyserial@495 f19166aa-fa4f-0410-85c2-fa1106f25c8a
Diffstat (limited to 'serial')
-rw-r--r-- | serial/rfc2217.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/serial/rfc2217.py b/serial/rfc2217.py index 2012ea7..3781ac6 100644 --- a/serial/rfc2217.py +++ b/serial/rfc2217.py @@ -442,7 +442,7 @@ class RFC2217Serial(SerialBase): timeout_time = time.time() + self._network_timeout while time.time() < timeout_time: time.sleep(0.05) # prevent 100% CPU load - if sum(o.active for o in mandadory_options) == len(mandadory_options): + if sum(o.active for o in mandadory_options) == sum(o.state != INACTIVE for o in mandadory_options): break else: raise SerialException("Remote does not seem to support RFC2217 or BINARY mode %r" % mandadory_options) |