diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2020-06-04 00:18:30 +0900 |
---|---|---|
committer | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2020-06-04 00:18:30 +0900 |
commit | 068b9b5738b4d41a25e14d56d6f6b55f3bc8d443 (patch) | |
tree | f58f2d43d8a54545ae8a0c51ffe99c310864710d /sphinx/util/console.py | |
parent | 88a3548a8268d3b99f2d79db08fe65da7d691592 (diff) | |
parent | 9b45b00bd4cee7dad96b98cec0224f88a84ef40a (diff) | |
download | sphinx-git-068b9b5738b4d41a25e14d56d6f6b55f3bc8d443.tar.gz |
Merge branch '3.x'
Diffstat (limited to 'sphinx/util/console.py')
-rw-r--r-- | sphinx/util/console.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sphinx/util/console.py b/sphinx/util/console.py index 98563f58e..d429be602 100644 --- a/sphinx/util/console.py +++ b/sphinx/util/console.py @@ -35,8 +35,7 @@ def get_terminal_width() -> int: import termios import fcntl import struct - call = fcntl.ioctl(0, termios.TIOCGWINSZ, # type: ignore - struct.pack('hhhh', 0, 0, 0, 0)) + call = fcntl.ioctl(0, termios.TIOCGWINSZ, struct.pack('hhhh', 0, 0, 0, 0)) height, width = struct.unpack('hhhh', call)[:2] terminal_width = width except Exception: |