fix input_in_time for linux
This commit is contained in:
1 parent
72797ce406
commit
90ae68ae61
1 file changed
+3
-1
@@ -378,7 +378,9 @@ class InteractBase(object):
|
|||||||
if time.time() - t > max_time_sec:
|
if time.time() - t > max_time_sec:
|
||||||
break
|
break
|
||||||
p.terminate()
|
p.terminate()
|
||||||
sys.stdin = os.fdopen( sys.stdin.fileno() )
|
old_stdin = sys.stdin
|
||||||
|
sys.stdin = os.fdopen( os.dup(sys.stdin.fileno()) )
|
||||||
|
old_stdin.close()
|
||||||
return inp
|
return inp
|
||||||
|
|
||||||
def input_process_skip_pending(self, stdin_fd):
|
def input_process_skip_pending(self, stdin_fd):
|
||||||
|
|||||||
Reference in new issue
Block a user