From 49c9d5f77a088c834aacad5d3dd7d876048b651d Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Wed, 7 Oct 2009 19:19:22 +0000 Subject: [PATCH] haubi reported that openpty no longer works on AIX either, so let's finish this and don't do openpty on non-Linux any more. Will port this to trunk. svn path=/main/branches/prefix/; revision=14514 --- pym/portage/__init__.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 6af4856d9..7667ccc4c 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -3868,14 +3868,18 @@ def _test_pty_eof(): # In some cases, openpty can be slow when it fails. Therefore, # stop trying to use it after the first failure. -if platform.system() in ["SunOS", "Darwin"]: - # disable the use of openpty on Solaris as it seems Python's openpty +if platform.system() not in ["Linux"]: + # Disable the use of openpty on Solaris as it seems Python's openpty # implementation doesn't play nice on Solaris with Portage's # behaviour causing hangs/deadlocks. - # disable on Darwin also, it used to work fine, but since the + # Disable on Darwin also, it used to work fine, but since the # introduction of _test_pty_eof Portage hangs (on the # slave_file.close()) indicating some other problems with openpty on # Darwin there + # On AIX, haubi reported that the openpty code doesn't work any + # longer since the introduction of _test_pty_eof either. + # Looks like Python's openpty module is too fragile to use on UNIX, + # so only use it on Linux _disable_openpty = True else: _disable_openpty = False -- 2.26.2