]> git.eshelyaron.com Git - emacs.git/commitdiff
(internal_self_insert): Avoid checking enable-multibyte-characters
authorKenichi Handa <handa@m17n.org>
Tue, 3 Mar 1998 01:29:16 +0000 (01:29 +0000)
committerKenichi Handa <handa@m17n.org>
Tue, 3 Mar 1998 01:29:16 +0000 (01:29 +0000)
twice.

src/cmds.c

index ba7745ac814e190d28e9321713df912c6007f132..cd814e6f706b8119be35b53c81fd5abace7da8ee 100644 (file)
@@ -342,9 +342,6 @@ internal_self_insert (c, noautofill)
   int chars_to_delete = 0;
   int spaces_to_insert = 0;
 
-  if (! NILP (current_buffer->enable_multibyte_characters))
-    c = unibyte_char_to_multibyte (c);
-
   overwrite = current_buffer->overwrite_mode;
   if (!NILP (Vbefore_change_function) || !NILP (Vafter_change_function)
       || !NILP (Vbefore_change_functions) || !NILP (Vafter_change_functions))
@@ -352,7 +349,10 @@ internal_self_insert (c, noautofill)
 
   /* At first, get multi-byte form of C in STR.  */
   if (!NILP (current_buffer->enable_multibyte_characters))
-    len = CHAR_STRING (c, workbuf, str);
+    {
+      c = unibyte_char_to_multibyte (c);
+      len = CHAR_STRING (c, workbuf, str);
+    }
   else
     workbuf[0] = c, str = workbuf, len = 1;