interactive shell bugfix : pupy server stdin was closed at exit because of the python gc

This commit is contained in:
n1nj4sec 2015-11-01 12:21:41 +01:00
parent 5d92fb5368
commit 7e5e036a09
2 changed files with 3 additions and 2 deletions

View File

@ -49,10 +49,9 @@ class InteractiveShell(PupyModule):
ps.start_read_loop(print_callback, is_closed.set)
try:
fd=sys.stdin.fileno()
f=os.fdopen(fd,'r')
old_settings = termios.tcgetattr(fd)
try:
tty.setraw(fd)
tty.setraw(sys.stdin.fileno())
input_buf=b""
while True:
r, w, x = select.select([sys.stdin], [], [], 0)

View File

@ -14,5 +14,7 @@ pyexec = pyexec
exec = shell_exec
ps = ps
migrate = migrate
shell=interactive_shell
kill = process_kill
killme = pyexec -c 'import os;os.kill(os.getpid(),9)'
#tasklist = shell_exec 'tasklist /v'