From 894ab63090276f27e9e3c051f6d2a852b3132650 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 15 Sep 1996 01:57:44 +0000 Subject: [PATCH] (gap_left, gap_right, modify_region): Compare overlay_unchanged_modified with OVERLAY_MODIFF. --- src/insdel.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/insdel.c b/src/insdel.c index 8b4cc5f8c2a..872858041eb 100644 --- a/src/insdel.c +++ b/src/insdel.c @@ -64,7 +64,8 @@ gap_left (pos, newgap) if (!newgap) { - if (unchanged_modified == MODIFF) + if (unchanged_modified == MODIFF + && overlay_unchanged_modified == OVERLAY_MODIFF) { beg_unchanged = pos; end_unchanged = Z - pos - 1; @@ -144,7 +145,9 @@ gap_right (pos) pos--; - if (unchanged_modified == MODIFF) + if (unchanged_modified == MODIFF + && overlay_unchanged_modified == OVERLAY_MODIFF) + { beg_unchanged = pos; end_unchanged = Z - pos - 1; @@ -716,10 +719,13 @@ modify_region (buffer, start, end) prepare_to_modify_buffer (start, end); - if (start - 1 < beg_unchanged || unchanged_modified == MODIFF) + if (start - 1 < beg_unchanged + || (unchanged_modified == MODIFF + && overlay_unchanged_modified == OVERLAY_MODIFF)) beg_unchanged = start - 1; if (Z - end < end_unchanged - || unchanged_modified == MODIFF) + || (unchanged_modified == MODIFF + && overlay_unchanged_modified == OVERLAY_MODIFF)) end_unchanged = Z - end; if (MODIFF <= SAVE_MODIFF) -- 2.39.2