on master help sign in
Whitespace
commit2fabd997b6726c5f1e57e213a63d498ad6f94ac2 authorJonathan Daugherty <cygnus@foobox.com> dateWed 15 Jul 2020, 13:50 (6 years ago) parent6a9c90d
1 file changed+5−5
cbits/gwinsz.c+5−5
cbits/gwinsz.c+5−5
@@ -1,11 +1,11 @@
11#include <sys/ioctl.h>
22
33unsigned long vty_c_get_window_size(int fd) {
4− struct winsize w;
5− if (ioctl (fd, TIOCGWINSZ, &w) >= 0)
6− return (w.ws_row << 16) + w.ws_col;
7− else
8− return 0x190050;
4+ struct winsize w;
5+ if (ioctl (fd, TIOCGWINSZ, &w) >= 0)
6+ return (w.ws_row << 16) + w.ws_col;
7+ else
8+ return 0x190050;
99}
1010
1111void vty_c_set_window_size(int fd, unsigned long val) {