disable the use of openpty on Solaris as it seems Python's openpty implementation...
authorFabian Groffen <grobian@gentoo.org>
Sat, 14 Mar 2009 12:08:49 +0000 (12:08 -0000)
committerFabian Groffen <grobian@gentoo.org>
Sat, 14 Mar 2009 12:08:49 +0000 (12:08 -0000)
svn path=/main/branches/prefix/; revision=13112

pym/portage/__init__.py

index 2a5248ff8f084eee0e648e5464806c2b5e2b4581..bee5d3554ef99aa998a109c326682b10ce9d9e3e 100644 (file)
@@ -3108,7 +3108,13 @@ def _shell_quote(s):
 
 # In some cases, openpty can be slow when it fails. Therefore,
 # stop trying to use it after the first failure.
-_disable_openpty = False
+if platform.system() in ["SunOS"]:
+       # 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_openpty = True
+else:
+       _disable_openpty = False
 
 def _create_pty_or_pipe(copy_term_size=None):
        """