]> git.eshelyaron.com Git - emacs.git/commitdiff
read_and_insert_process_output: Call 'prepare_to_modify_buffer' first
authorDmitry Gutov <dmitry@gutov.dev>
Tue, 11 Jun 2024 01:51:25 +0000 (04:51 +0300)
committerEshel Yaron <me@eshelyaron.com>
Wed, 12 Jun 2024 09:27:20 +0000 (11:27 +0200)
* src/process.c (read_and_insert_process_output): Call
'prepare_to_modify_buffer' before any insertions (bug#71452).

(cherry picked from commit 5a576069fcd803a6a5260a2da8ce0862be982eb4)

src/process.c

index 547cdbb0c45c44fff5668f1452ca36b272f7814c..c00eba086a2acc9e3acdd403b1e98dffea7fd278 100644 (file)
@@ -6362,6 +6362,8 @@ read_and_insert_process_output (struct Lisp_Process *p, char *buf,
                                     &opoint_byte);
 
   /* Adapted from call_process.  */
+  prepare_to_modify_buffer (PT, PT, NULL);
+
   if (NILP (BVAR (XBUFFER (p->buffer), enable_multibyte_characters))
           && ! CODING_MAY_REQUIRE_DECODING (process_coding))
     {