summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/JobStatusDisplay.py
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-07-12 01:41:09 -0700
committerZac Medico <zmedico@gentoo.org>2011-07-12 01:41:09 -0700
commit5df96179611ce0e98727945b1800b43daccedfc2 (patch)
treee60d86543cf61b8f8fa93858c4068b2305a6769b /pym/_emerge/JobStatusDisplay.py
parent428053ee44e4a14b3c74dc8e541bcb062b31a799 (diff)
downloadportage-5df96179611ce0e98727945b1800b43daccedfc2.tar.gz
portage-5df96179611ce0e98727945b1800b43daccedfc2.tar.bz2
portage-5df96179611ce0e98727945b1800b43daccedfc2.zip
Remove python-2.6 StringIO.StringIO fallback.
Since the io module in python-2.6 was broken when threading was disabled, we needed to fall back from io.StringIO to StringIO.StringIO in this case (typically just for Gentoo's stage1 and stage2 tarballs). Now that python-2.7 is stable in stages and we rely on io.open() being available, we can also rely on io.StringIO being available.
Diffstat (limited to 'pym/_emerge/JobStatusDisplay.py')
-rw-r--r--pym/_emerge/JobStatusDisplay.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/pym/_emerge/JobStatusDisplay.py b/pym/_emerge/JobStatusDisplay.py
index d3d330d30..1949232e7 100644
--- a/pym/_emerge/JobStatusDisplay.py
+++ b/pym/_emerge/JobStatusDisplay.py
@@ -1,12 +1,12 @@
-# Copyright 1999-2009 Gentoo Foundation
+# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
import formatter
+import io
import sys
import time
import portage
-from portage import StringIO
from portage import os
from portage import _encodings
from portage import _unicode_decode
@@ -237,8 +237,8 @@ class JobStatusDisplay(object):
failed_str = str(self.failed)
load_avg_str = self._load_avg_str()
- color_output = StringIO()
- plain_output = StringIO()
+ color_output = io.StringIO()
+ plain_output = io.StringIO()
style_file = portage.output.ConsoleStyleFile(color_output)
style_file.write_listener = plain_output
style_writer = portage.output.StyleWriter(file=style_file, maxcol=9999)