From 6f5b891b7b815b192581c89116e60a8ed7eb5009 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Wed, 6 May 2009 17:16:33 +0000 Subject: * fhandler_console.cc (fhandler_console::ioctl): Properly treat TIOCLINUX argument as a char. * fhandler_tty.cc (fhandler_tty_slave::ioctl): Use coercion to properly set char value. --- winsup/cygwin/fhandler_console.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'winsup/cygwin/fhandler_console.cc') diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc index 965f8aadf..a2b2cd38c 100644 --- a/winsup/cygwin/fhandler_console.cc +++ b/winsup/cygwin/fhandler_console.cc @@ -723,9 +723,9 @@ fhandler_console::ioctl (unsigned int cmd, void *buf) } return 0; case TIOCLINUX: - if (* (int *) buf == 6) + if (*(unsigned char *) buf == 6) { - * (int *) buf = dev_state->nModifiers; + *(unsigned char *) buf = (unsigned char) dev_state->nModifiers; return 0; } else -- cgit v1.2.3