Mercurial > hg
comparison mercurial/ui.py @ 1609:c50bddfbc812
eliminate backtrace when piping output on windows.
this fixes issue 54.
author | Vadim Gelfer <vadim.gelfer@gmail.com> |
---|---|
date | Mon, 02 Jan 2006 15:25:33 -0800 |
parents | dd186cb70a64 |
children | 3b1b44b917f4 |
comparison
equal
deleted
inserted
replaced
1608:722fd16f6f8c | 1609:c50bddfbc812 |
---|---|
108 def write(self, *args): | 108 def write(self, *args): |
109 for a in args: | 109 for a in args: |
110 sys.stdout.write(str(a)) | 110 sys.stdout.write(str(a)) |
111 | 111 |
112 def write_err(self, *args): | 112 def write_err(self, *args): |
113 sys.stdout.flush() | 113 if not sys.stdout.closed: sys.stdout.flush() |
114 for a in args: | 114 for a in args: |
115 sys.stderr.write(str(a)) | 115 sys.stderr.write(str(a)) |
116 | 116 |
117 def readline(self): | 117 def readline(self): |
118 return sys.stdin.readline()[:-1] | 118 return sys.stdin.readline()[:-1] |