projects
/
portage.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f07ba1d
)
Use Popen.communicate() to avoid a potential deadlock.
author
Zac Medico
<zmedico@gentoo.org>
Fri, 27 Feb 2009 05:23:37 +0000
(
05:23
-0000)
committer
Zac Medico
<zmedico@gentoo.org>
Fri, 27 Feb 2009 05:23:37 +0000
(
05:23
-0000)
svn path=/main/trunk/; revision=12729
pym/portage/sets/shell.py
patch
|
blob
|
history
diff --git
a/pym/portage/sets/shell.py
b/pym/portage/sets/shell.py
index 8114b5133f0db3b1af168f907fb54d7a3628bb6d..43a8fe02f722e145eaa3c5fe42cca3c53aee7511 100644
(file)
--- a/
pym/portage/sets/shell.py
+++ b/
pym/portage/sets/shell.py
@@
-33,9
+33,9
@@
class CommandOutputSet(PackageSet):
def load(self):
pipe = subprocess.Popen(self._command, stdout=subprocess.PIPE, shell=True)
+ stdout, stderr = pipe.communicate()
if pipe.wait() == os.EX_OK:
- text = unicode(pipe.stdout.read(), errors='replace')
- self._setAtoms(text.splitlines())
+ self._setAtoms(unicode(stdout, errors='replace').splitlines())
def singleBuilder(self, options, settings, trees):
if not "command" in options: