From b83058fd179b6de492fa3ed6292d2821ca253806 Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Mon, 8 Aug 2005 05:53:02 +0000 Subject: activate LC_CTYPE for 8 bits locale. Make sure tolower/toupper use the whole 8 bits. okay deraadt@ thanks to everyone who tested --- include/ctype.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include/ctype.h') diff --git a/include/ctype.h b/include/ctype.h index 753c68a7de9..25f551d9c09 100644 --- a/include/ctype.h +++ b/include/ctype.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ctype.h,v 1.17 2004/04/02 22:37:12 avsm Exp $ */ +/* $OpenBSD: ctype.h,v 1.18 2005/08/08 05:53:00 espie Exp $ */ /* $NetBSD: ctype.h,v 1.14 1994/10/26 00:55:47 cgd Exp $ */ /* @@ -147,14 +147,14 @@ __CTYPE_INLINE int isxdigit(int c) __CTYPE_INLINE int tolower(int c) { - if ((unsigned int)c > 0177) + if ((unsigned int)c > 255) return (c); return ((_tolower_tab_ + 1)[c]); } __CTYPE_INLINE int toupper(int c) { - if ((unsigned int)c > 0177) + if ((unsigned int)c > 255) return (c); return ((_toupper_tab_ + 1)[c]); } -- cgit v1.2.3