From: Paul Eggert Date: Sun, 25 Sep 2011 01:28:59 +0000 (-0700) Subject: * coding.c (ENCODE_ISO_CHARACTER): Use unsigned, not int, X-Git-Tag: emacs-24.2.90~471^2~6^2~195 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=47664caabe10c081360a1dcf58492163e9f5b43c;p=emacs.git * coding.c (ENCODE_ISO_CHARACTER): Use unsigned, not int, to store the unsigned result of ENCODE_CHAR. --- diff --git a/src/ChangeLog b/src/ChangeLog index 2e632bc5ad8..d3ab346a380 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -169,6 +169,8 @@ Use ptrdiff_t, not int, to avoid needless 32-bit limit on 64-bit hosts. (Ffind_operation_coding_system): NATNUMP can eval its arg twice. (Fdefine_coding_system_internal): Check for charset-id overflow. + (ENCODE_ISO_CHARACTER): Use unsigned, not int, to store the unsigned + result of ENCODE_CHAR. * coding.h: Adjust decls to match defn changes elsewhere. (struct coding_system): Use ptrdiff_t, not EMACS_INT, where ptrdiff_t is wide enough. diff --git a/src/coding.c b/src/coding.c index 704d26f3f9b..44506476794 100644 --- a/src/coding.c +++ b/src/coding.c @@ -4185,7 +4185,7 @@ decode_coding_iso_2022 (struct coding_system *coding) #define ENCODE_ISO_CHARACTER(charset, c) \ do { \ - int code = ENCODE_CHAR ((charset), (c)); \ + unsigned code = ENCODE_CHAR ((charset), (c)); \ \ if (CHARSET_DIMENSION (charset) == 1) \ ENCODE_ISO_CHARACTER_DIMENSION1 ((charset), code); \