From: Zac Medico Date: Sun, 7 Jul 2013 02:16:56 +0000 (-0700) Subject: ForkProcess: flush stderr for traceback X-Git-Tag: v2.2.0_alpha187~9 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=1aae13adbc8648d3763e1570ddeffb2536c5d826;p=portage.git ForkProcess: flush stderr for traceback --- diff --git a/pym/portage/util/_async/ForkProcess.py b/pym/portage/util/_async/ForkProcess.py index be856d039..25f72d308 100644 --- a/pym/portage/util/_async/ForkProcess.py +++ b/pym/portage/util/_async/ForkProcess.py @@ -1,7 +1,8 @@ -# Copyright 2012 Gentoo Foundation +# Copyright 2012-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 import signal +import sys import traceback import portage @@ -46,6 +47,8 @@ class ForkProcess(SpawnProcess): raise except: traceback.print_exc() + # os._exit() skips stderr flush! + sys.stderr.flush() finally: os._exit(rval)