changeset 88507:e3a506b5f300

(Fset_buffer_multibyte): Convert 8-bit bytes to multibyte form correctly.
author Kenichi Handa <handa@m17n.org>
date Tue, 14 May 2002 11:50:46 +0000
parents a7f0d13affa5
children 2099aaefdcbb
files src/buffer.c
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/buffer.c	Tue May 14 11:47:35 2002 +0000
+++ b/src/buffer.c	Tue May 14 11:50:46 2002 +0000
@@ -2161,8 +2161,9 @@
 	  else
 	    {
 	      unsigned char tmp[MAX_MULTIBYTE_LENGTH];
-
-	      bytes = CHAR_STRING (*p, tmp);
+	      int c = BYTE8_TO_CHAR (*p);
+
+	      bytes = CHAR_STRING (c, tmp);
 	      *p = tmp[0];
 	      TEMP_SET_PT_BOTH (pos + 1, pos + 1);
 	      bytes--;