From 3073601217d7ec1536d90c4586dcc3b740096765 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Thu, 21 Dec 2000 00:12:13 +0000 Subject: [PATCH] (Fmake_char_internal): If CHARSET doesn't have a generic character and CODE1 is nil, return the smallest character in CHARSET. --- src/charset.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/charset.c b/src/charset.c index 58123244486..21583c8e8c3 100644 --- a/src/charset.c +++ b/src/charset.c @@ -967,13 +967,17 @@ DEFUN ("make-char-internal", Fmake_char_internal, Smake_char_internal, 1, 3, 0, } else if (charset_id == CHARSET_8_BIT_CONTROL) { - if (c1 < 0x80 || c1 > 0x9F) + if (NILP (code1)) + c1 = 0x80; + else if (c1 < 0x80 || c1 > 0x9F) goto invalid_code_posints; return make_number (c1); } else if (charset_id == CHARSET_8_BIT_GRAPHIC) { - if (c1 < 0xA0 || c1 > 0xFF) + if (NILP (code1)) + c1 = 0xA0; + else if (c1 < 0xA0 || c1 > 0xFF) goto invalid_code_posints; return make_number (c1); } -- 2.39.2