changeset 107988:b7a5dd2fb441

charset.c (char_charset): Consider Vcharset_non_preferred_head only when the arg CHARSET_LIST is nil.
author Kenichi Handa <handa@etlken>
date Tue, 20 Apr 2010 16:27:15 +0900
parents bef5d1738c0b (current diff) 54f7ec0a9243 (diff)
children d94009e7a0cc
files
diffstat 2 files changed, 10 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Mon Apr 19 21:50:52 2010 -0400
+++ b/src/ChangeLog	Tue Apr 20 16:27:15 2010 +0900
@@ -1,3 +1,8 @@
+2010-04-20  Kenichi Handa  <handa@m17n.org>
+
+	* charset.c (char_charset): Consider Vcharset_non_preferred_head
+	only when the arg CHARSET_LIST is nil.
+
 2010-04-20  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	Make variable forwarding explicit rather the using special values.
@@ -110,6 +115,8 @@
 
 	* .gdbinit (xsubchartable): New command.
 
+2010-04-19  Eli Zaretskii  <eliz@gnu.org>
+
 	* xdisp.c (display_line): Don't write beyond the last glyph row in
 	the desired matrix.  Fixes a crash in "emacs -nw" (bug#5972), see
 	http://lists.gnu.org/archive/html/emacs-devel/2010-04/msg00075.html
--- a/src/charset.c	Mon Apr 19 21:50:52 2010 -0400
+++ b/src/charset.c	Tue Apr 20 16:27:15 2010 +0900
@@ -2082,8 +2082,9 @@
 	  return charset;
 	}
       charset_list = XCDR (charset_list);
-      if (c <= MAX_UNICODE_CHAR
-	 && EQ (charset_list, Vcharset_non_preferred_head))
+      if (! maybe_null
+	  && c <= MAX_UNICODE_CHAR
+	  && EQ (charset_list, Vcharset_non_preferred_head))
 	return CHARSET_FROM_ID (charset_unicode);
     }
   return (maybe_null ? NULL