From cbb38e0e818ffbf678e28fc428c2d392e6209832 Mon Sep 17 00:00:00 2001 From: avolkov Date: Thu, 12 Jan 2006 00:46:02 +0000 Subject: [PATCH] A more precise iswgraph() backup (forgot to commit before) git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@2163 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/src/port.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sc2/src/port.h b/sc2/src/port.h index 0f555fc81..650c5ea2b 100644 --- a/sc2/src/port.h +++ b/sc2/src/port.h @@ -133,8 +133,8 @@ typedef unsigned int wint_t; # include static inline int iswgraph(wint_t wc) -{ - return wc > 0x7f || isgraph((int) wc); +{ // this is not exact as UCS defines many more non-printable + return wc > 0xa0 || (wc < 0x80 && isgraph((int) wc)); } #endif