##// END OF EJS Templates
ignore EPIPE in ui.err_write...
Benoit Boissinot -
r1989:0541768f default
parent child Browse files
Show More
@@ -8,7 +8,7 b''
8 import ConfigParser
8 import ConfigParser
9 from i18n import gettext as _
9 from i18n import gettext as _
10 from demandload import *
10 from demandload import *
11 demandload(globals(), "os re socket sys util tempfile")
11 demandload(globals(), "errno os re socket sys tempfile util")
12
12
13 class ui(object):
13 class ui(object):
14 def __init__(self, verbose=False, debug=False, quiet=False,
14 def __init__(self, verbose=False, debug=False, quiet=False,
@@ -179,9 +179,13 b' class ui(object):'
179 sys.stdout.write(str(a))
179 sys.stdout.write(str(a))
180
180
181 def write_err(self, *args):
181 def write_err(self, *args):
182 if not sys.stdout.closed: sys.stdout.flush()
182 try:
183 for a in args:
183 if not sys.stdout.closed: sys.stdout.flush()
184 sys.stderr.write(str(a))
184 for a in args:
185 sys.stderr.write(str(a))
186 except IOError, inst:
187 if inst.errno != errno.EPIPE:
188 raise
185
189
186 def flush(self):
190 def flush(self):
187 try:
191 try:
General Comments 0
You need to be logged in to leave comments. Login now