From: Richard M. Stallman Date: Sat, 22 May 2004 22:19:28 +0000 (+0000) Subject: (casify_object): Return OBJ unchanged if not real char. X-Git-Tag: ttn-vms-21-2-B4~6091 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=69fe4180e4a4d44fc2579e488204031c6e012917;p=emacs.git (casify_object): Return OBJ unchanged if not real char. --- diff --git a/src/casefiddle.c b/src/casefiddle.c index ae60d2c8dd5..6387c4bc845 100644 --- a/src/casefiddle.c +++ b/src/casefiddle.c @@ -52,6 +52,12 @@ casify_object (flag, obj) | CHAR_SHIFT | CHAR_CTL | CHAR_META); int flags = XINT (obj) & flagbits; + /* If the character has higher bits set + above the flags, return it unchanged. + It is not a real character. */ + if ((unsigned) XFASTINT (obj) > (unsigned) flagbits) + return obj; + c = DOWNCASE (XFASTINT (obj) & ~flagbits); if (inword) XSETFASTINT (obj, c | flags);