bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#33975: [PATCH] inhibit read-only text properties in comint-interrupt


From: Alex Branham
Subject: bug#33975: [PATCH] inhibit read-only text properties in comint-interrupt-subjob
Date: Fri, 04 Jan 2019 10:35:05 -0600
User-agent: mu4e 1.1.0; emacs 27.0.50

Hi -

This patch inhibits read-only properties during comint-interrupt-subjob.
I ran across this while using ESS and (setq comint-prompt-read-only t).
There's a little more info (including a reproducible example) on ESS's
bugtracker.[1]

Thanks,
Alex

From 8e3885c5b9747987cacd3b17b9de29975e7691e3 Mon Sep 17 00:00:00 2001
From: Alex Branham <address@hidden>
Date: Fri, 4 Jan 2019 10:28:09 -0600
Subject: [PATCH] * lisp/comint.el (comint-interrupt-subjob): Inhibit read only

Otherwise with comint-prompt-read-only set to t users can be incapable
of interrupting running busy processes. See ESS's issue tracker for
details: https://github.com/emacs-ess/ESS/issues/792
---
 lisp/comint.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lisp/comint.el b/lisp/comint.el
index 0a6aff2e73..2ed65c1c1c 100644
--- a/lisp/comint.el
+++ b/lisp/comint.el
@@ -2500,8 +2500,9 @@ comint-clear-buffer
 (defun comint-interrupt-subjob ()
   "Interrupt the current subjob."
   (interactive)
-  (comint-skip-input)
-  (interrupt-process nil comint-ptyp)
+  (let ((inhibit-read-only t))
+    (comint-skip-input)
+    (interrupt-process nil comint-ptyp))
   ;; (process-send-string nil "\n")
   )

--
2.19.2


Attachment: 0001-lisp-comint.el-comint-interrupt-subjob-Inhibit-read-.patch
Description: Text Data

Footnotes:
[1]  https://github.com/emacs-ess/ESS/issues/792

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]