]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix Bug#56110 (switching from line-mode to char-mode)
authorMichael Heerdegen <michael_heerdegen@web.de>
Tue, 21 Jun 2022 11:41:51 +0000 (13:41 +0200)
committerMichael Heerdegen <michael_heerdegen@web.de>
Sun, 26 Jun 2022 14:41:30 +0000 (16:41 +0200)
* lisp/term.el (term-char-mode): Make `add-function' override the
correct place (the buffer local variable `term-input-sender').

lisp/term.el

index 94bf13e9736ae7a12ae25e0cab8cccd4aa08e9fd..a8e44b4c34fe8f9b6b97e76fde166f72813a0f03 100644 (file)
@@ -1467,10 +1467,10 @@ process."
       (when (> (point) pmark)
        (unwind-protect
            (progn
-             (add-function :override term-input-sender #'term-send-string)
+             (add-function :override (local 'term-input-sender) #'term-send-string)
              (end-of-line)
              (term-send-input))
-         (remove-function term-input-sender #'term-send-string))))
+         (remove-function (local 'term-input-sender) #'term-send-string))))
     (term-update-mode-line)))
 
 (defun term-line-mode  ()