author | Steve Borho <steve@borho.org> |
Sat, 22 Jan 2011 09:13:04 -0600 | |
changeset 13286 | 189edd1b15fb |
parent 13284 | 77351c88dd10 (current diff) |
parent 13285 | 2ef915184ff2 (diff) |
child 13288 | 9c3bfba3f48d |
--- a/mercurial/win32.py Fri Jan 21 16:26:01 2011 -0600 +++ b/mercurial/win32.py Sat Jan 22 09:13:04 2011 -0600 @@ -170,6 +170,8 @@ try: # Query stderr to avoid problems with redirections screenbuf = win32console.GetStdHandle(win32console.STD_ERROR_HANDLE) + if screenbuf is None: + return 79 try: window = screenbuf.GetConsoleScreenBufferInfo()['Window'] width = window.Right - window.Left