summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjquast <contact@jeffquast.com>2014-05-24 22:46:45 -0700
committerjquast <contact@jeffquast.com>2014-05-24 22:47:17 -0700
commitcccf1b3bfd47ec176c1775fedbff66fc15b3fcf9 (patch)
treeb9ee787fb43a2cab2e799167488a9859b6e28812
parentef96998e5f02edb0b2c13845a60089038a49302e (diff)
downloadpexpect-issue-20.tar.gz
additional Nonetype timeout accomidationissue-20
-rw-r--r--pexpect/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/pexpect/__init__.py b/pexpect/__init__.py
index 074bc99..8017123 100644
--- a/pexpect/__init__.py
+++ b/pexpect/__init__.py
@@ -882,8 +882,8 @@ class spawn(object):
if timeout == -1:
timeout = self.timeout
-
- poll_exit = min(poll_exit, timeout)
+ elif timeout is not None:
+ poll_exit = min(poll_exit, timeout)
# Note that some systems such as Solaris do not give an EOF when
# the child dies. In fact, you can still try to read