changeset 23258:2f8585bcea90

(code_convert_region): Update beg_unchanged and end_unchanged after we delete the source text.
author Kenichi Handa <handa@m17n.org>
date Wed, 16 Sep 1998 07:21:31 +0000
parents b72cefab3254
children a3f818e927ba
files src/coding.c
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/coding.c	Wed Sep 16 07:21:31 1998 +0000
+++ b/src/coding.c	Wed Sep 16 07:21:31 1998 +0000
@@ -4212,11 +4212,6 @@
     make_gap (require - GAP_SIZE);
   move_gap_both (from, from_byte);
 
-  if (GPT - BEG < beg_unchanged)
-    beg_unchanged = GPT - BEG;
-  if (Z - GPT < end_unchanged)
-    end_unchanged = Z - GPT;
-
   inserted = inserted_byte = 0;
   src = GAP_END_ADDR, dst = GPT_ADDR;
 
@@ -4226,6 +4221,11 @@
   ZV_BYTE -= len_byte;
   Z_BYTE -= len_byte;
 
+  if (GPT - BEG < beg_unchanged)
+    beg_unchanged = GPT - BEG;
+  if (Z - GPT < end_unchanged)
+    end_unchanged = Z - GPT;
+
   for (;;)
     {
       int result;