You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
waf/waf-1.4.2-fcntl.patch

21 lines
664 B

--- waf-1.4.2/wafadmin/Utils.py 2008-05-16 17:43:19.000000000 +0200
+++ waf-1.4.2.fcntl/wafadmin/Utils.py 2008-05-26 09:23:19.000000000 +0200
@@ -154,10 +154,13 @@ except ImportError:
return 55
else:
def get_term_cols():
- dummy_lines, cols = struct.unpack("HHHH", \
- fcntl.ioctl(sys.stdout.fileno(),termios.TIOCGWINSZ , \
- struct.pack("HHHH", 0, 0, 0, 0)))[:2]
- return cols
+ try:
+ dummy_lines, cols = struct.unpack("HHHH", \
+ fcntl.ioctl(sys.stdout.fileno(),termios.TIOCGWINSZ , \
+ struct.pack("HHHH", 0, 0, 0, 0)))[:2]
+ return cols
+ except IOError:
+ return 55
def progress_line(state, total, col1, col2):
n = len(str(total))