subprocess: listen: exit normally with EOFError

This is an expected case, since the parent closed normally, and
therefore the subprocess should exit with 0.
This commit is contained in:
Daniel Hahler
2018-07-10 13:05:33 +02:00
committed by Dave Halter
parent f3c1f4c548
commit 87d7c59c6e

View File

@@ -304,9 +304,9 @@ class Listener(object):
try: try:
payload = pickle_load(stdin) payload = pickle_load(stdin)
except EOFError: except EOFError:
# It looks like the parent process closed. Don't make a big fuss # It looks like the parent process closed.
# here and just exit. # Don't make a big fuss here and just exit.
exit(1) exit(0)
try: try:
result = False, None, self._run(*payload) result = False, None, self._run(*payload)
except Exception as e: except Exception as e: