For bug #185930, direct all FETCHCOMMAND output to stdout. (branches/2.1.2 r7331)
authorZac Medico <zmedico@gentoo.org>
Mon, 30 Jul 2007 06:55:10 +0000 (06:55 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 30 Jul 2007 06:55:10 +0000 (06:55 -0000)
svn path=/main/branches/2.1.2.9/; revision=7503

pym/portage.py

index 8f1a16957a2795c3c8ef02959d447f4c6bba1766..369e0bb4e159e8a7be2d1d8bb431eb81fba2036a 100644 (file)
@@ -2644,6 +2644,14 @@ def fetch(myuris, mysettings, listonly=0, fetchonly=0, locks_in_subdir=".locks",
                                        myfetch = [varexpand(x, mydict=variables) for x in lexer]
 
                                        spawn_keywords = {}
+                                       # Redirect all output to stdout since some fetchers like
+                                       # wget pollute stderr (if portage detects a problem then it
+                                       # can send it's own message to stderr).
+                                       spawn_keywords["fd_pipes"] = {
+                                               0:sys.stdin.fileno(),
+                                               1:sys.stdout.fileno(),
+                                               2:sys.stdout.fileno()
+                                       }
                                        if "userfetch" in mysettings.features and \
                                                os.getuid() == 0 and portage_gid and portage_uid:
                                                spawn_keywords.update({