aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/charset.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/charset.h b/src/charset.h
index 5ee27bf9003..9645db2a054 100644
--- a/src/charset.h
+++ b/src/charset.h
@@ -612,10 +612,9 @@ else
612 612
613/* Return the length of the multi-byte form at string STR of length LEN. */ 613/* Return the length of the multi-byte form at string STR of length LEN. */
614 614
615#define MULTIBYTE_FORM_LENGTH(str, len) \ 615#define MULTIBYTE_FORM_LENGTH(str, len) \
616 ((BYTES_BY_CHAR_HEAD (*(unsigned char *)(str)) == 1 \ 616 (BYTES_BY_CHAR_HEAD (*(unsigned char *)(str)) == 1 \
617 || BYTES_BY_CHAR_HEAD (*(unsigned char *)(str)) > (len)) \ 617 ? 1 \
618 ? 1 \
619 : multibyte_form_length (str, len)) 618 : multibyte_form_length (str, len))
620 619
621/* Set C a (possibly multibyte) character at P. P points into a 620/* Set C a (possibly multibyte) character at P. P points into a