The SunOS struct ttysize had fields of type "int"; update termios.tcgetwinsize().

Signed-off-by: Soumendra Ganguly <soumendraganguly@gmail.com>
This commit is contained in:
Soumendra Ganguly 2020-12-15 05:42:20 -06:00
parent 6ef8a2921c
commit 91374ea951
1 changed files with 2 additions and 2 deletions

View File

@ -432,8 +432,8 @@ termios_tcsetwinsize_impl(PyObject *module, int fd, PyObject *winsz)
return PyErr_SetFromErrno(state->TermiosError);
}
s.ts_lines = (unsigned short) PyLong_AsLong(PyList_GetItem(winsz, 0));
s.ts_cols = (unsigned short) PyLong_AsLong(PyList_GetItem(winsz, 1));
s.ts_lines = (int) PyLong_AsLong(PyList_GetItem(winsz, 0));
s.ts_cols = (int) PyLong_AsLong(PyList_GetItem(winsz, 1));
if (PyErr_Occurred()) {
return NULL;
}