[Python-checkins] r63576 - python/trunk/Lib/test/test_ioctl.py
martin.v.loewis
python-checkins at python.org
Sat May 24 11:36:45 CEST 2008
Author: martin.v.loewis
Date: Sat May 24 11:36:45 2008
New Revision: 63576
Log:
Don't try to get the window size if it was never set before.
Fixes the test failure on Solaris.
Modified:
python/trunk/Lib/test/test_ioctl.py
Modified: python/trunk/Lib/test/test_ioctl.py
==============================================================================
--- python/trunk/Lib/test/test_ioctl.py (original)
+++ python/trunk/Lib/test/test_ioctl.py Sat May 24 11:36:45 2008
@@ -52,13 +52,10 @@
set_winsz_opcode_maybe_neg, = struct.unpack("i",
struct.pack("I", termios.TIOCSWINSZ))
- # We're just testing that these calls do not raise exceptions.
- saved_winsz = fcntl.ioctl(mfd, termios.TIOCGWINSZ, "\0"*8)
our_winsz = struct.pack("HHHH",80,25,0,0)
# test both with a positive and potentially negative ioctl code
new_winsz = fcntl.ioctl(mfd, set_winsz_opcode_pos, our_winsz)
new_winsz = fcntl.ioctl(mfd, set_winsz_opcode_maybe_neg, our_winsz)
- fcntl.ioctl(mfd, set_winsz_opcode_maybe_neg, saved_winsz)
finally:
os.close(mfd)
os.close(sfd)
More information about the Python-checkins
mailing list