Subject: bug#30544: 26.0.91; ansi-term duplicates 2 line zsh prompts any time windows change (maybe other times)

From: Eli Zaretskii <[email-masked]>
Date: Wed, 14 Mar 2018 20:30:32 +0200

> From: Aaron Jensen <[email-masked]>
> Date: Wed, 14 Mar 2018 11:08:32 -0700
> Cc: [email-masked], Noam Postavsky <[email-masked]>
> 
> On Wed, Mar 14, 2018 at 10:34 AM, Eli Zaretskii <[email-masked]> wrote:
> >> From: Aaron Jensen <[email-masked]>
> >> Date: Wed, 14 Mar 2018 08:59:55 -0700
> >> Cc: Noam Postavsky <[email-masked]>
> >>
> >> I saw that you've been doing some term.el work recently. Do you have
> >> an idea what could be causing this?
> >
> > See Glenn's message with bisection: as expected, this is due to the
> > telling the shell to resize its window.
> 
> I don't know if this was directed at Noam or myself

It was meant to answer your question.

> but one interesting thing is that iTerm also has artifacts when
> resizing, but only if resizing to be horizontally smaller. term.el
> appears to have artifacts every time any size change is made
> (horizontal or vertical).

I think the problem in term.el is because we send the TIOCSWINSZ ioctl
when we shouldn't, see window-adjust-process-window-size-function and
set-process-window-size.  We had similar issues in the past, see
bug#24465.