From 5514cce54eeb6b5b2fc4bc8ec005b474e563c9e2 Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Sat, 20 Nov 1999 18:52:01 +0000 Subject: ioctl arguments are u_long. Replaces `undefined' code with `defined' behavior... gcc 2.96 performs switch cases range analysis, warns about unreachable cases, and weeds them out. In switch(i) { case VALUE: } VALUE is first coerced into the type of i. If i is signed, VALUE is unsigned and exceeds i range, you lose... the result of the conversion is undefined. --- sys/arch/i386/isa/pcvt/pcvt_kbd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/arch/i386/isa/pcvt/pcvt_kbd.c') diff --git a/sys/arch/i386/isa/pcvt/pcvt_kbd.c b/sys/arch/i386/isa/pcvt/pcvt_kbd.c index 5add2e802c5..03d2ede8a0e 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_kbd.c +++ b/sys/arch/i386/isa/pcvt/pcvt_kbd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pcvt_kbd.c,v 1.27 1999/10/07 02:43:08 aaron Exp $ */ +/* $OpenBSD: pcvt_kbd.c,v 1.28 1999/11/20 18:52:00 espie Exp $ */ /* * Copyright (c) 1992, 1995 Hellmuth Michaelis and Joerg Wunsch. @@ -1838,7 +1838,7 @@ setkeydef(Ovl_tbl *data) * keyboard ioctl's entry *---------------------------------------------------------------------------*/ int -kbdioctl(Dev_t dev, int cmd, caddr_t data, int flag) +kbdioctl(Dev_t dev, u_long cmd, caddr_t data, int flag) { int key; -- cgit v1.2.3