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

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

bug#48716: 28.0.50; Spurious output from term-emulate-terminal when in l


From: Sean Whitton
Subject: bug#48716: 28.0.50; Spurious output from term-emulate-terminal when in line-mode
Date: Thu, 02 Jun 2022 19:46:14 -0700
User-agent: Notmuch/0.36 Emacs/29.0.50 (x86_64-pc-linux-gnu)

Hello,

On Fri 28 May 2021 at 04:00PM +01, Massimiliano Mirra wrote:

> Spurious output is occasionally produced when running a command
> with `make-term', and the command performs cursor movements and
> partial screen clears.
>
> [...]
>
> The culprit appears to be following lines from `term-emulate-terminal'
> in term.el; commenting them out fixes this problem:
>
>    (when (and (> (point-max) (process-mark proc))
>       (term-in-line-mode))
>      (narrow-to-region (point-min) (process-mark proc)))

The code assumes anything after the process mark is prospective input,
which is very often going to be wrong when the command moves the cursor
-- even if the command just emits \r.  One way to fix this might be to
add text properties to actual output, thereby distinguishing it from
something the user has typed.

-- 
Sean Whitton





reply via email to

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