From 80bc0a65ced0c1206551d3d855c1dad2464b439a Mon Sep 17 00:00:00 2001 From: Thomas Nagy Date: Wed, 1 Jan 2014 19:59:59 +0100 Subject: [PATCH] moved the TINY_STEP variable to the module level --- waflib/ansiterm.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/waflib/ansiterm.py b/waflib/ansiterm.py index 66dd2017..8f38e2bc 100644 --- a/waflib/ansiterm.py +++ b/waflib/ansiterm.py @@ -13,6 +13,8 @@ console commands. import sys, os, re, threading +TINY_STEP = 3000 + try: if not (sys.stderr.isatty() and sys.stdout.isatty()): raise ValueError('not a tty') @@ -241,7 +243,6 @@ else: if isinstance(txt, _type): writeconsole = windll.kernel32.WriteConsoleW - TINY_STEP = 3000 for x in range(0, len(txt), TINY_STEP): # According MSDN, size should NOT exceed 64 kb (issue #746) tiny = txt[x : x + TINY_STEP]