Mercurial > emacs
changeset 23665:53553d8b253e
(string_to_non_ascii_char): Return correct length for
a charset of dimension 2 and composition character.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Mon, 09 Nov 1998 07:06:11 +0000 |
parents | bf72d6351f29 |
children | 53776c6e94b8 |
files | src/charset.c |
diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/charset.c Sun Nov 08 17:24:16 1998 +0000 +++ b/src/charset.c Mon Nov 09 07:06:11 1998 +0000 @@ -208,8 +208,10 @@ if (cmpchar_id >= 0) { c = MAKE_COMPOSITE_CHAR (cmpchar_id); - str += cmpchar_table[cmpchar_id]->len; + str += cmpchar_table[cmpchar_id]->len - 1; } + else + str += bytes - 1; } else { @@ -230,7 +232,7 @@ if (CHARSET_DEFINED_P (charset) && CHARSET_DIMENSION (charset) == 2 && str < endp) - c2 = *str & 0x7F; + c2 = *str++ & 0x7F; c = MAKE_NON_ASCII_CHAR (charset, c1, c2); } } while (0);