Subject: bug#19945: emacsclient confused by active minibuffer

From: Lars Ingebrigtsen <[email-masked]>
Date: Thu, 03 Dec 2020 12:44:08 +0100

Noé Rubinstein <[email-masked]> writes:

> Steps to reproduce:
> * In terminal 1: emacs -Q -nw
> * M-x server-start RET
> * M-x
> * In terminal 2: emacsclient -t foo.txt
>
> Expected result:
> * terminal 1 displays *scratch*
> * terminal 2 displays foo.txt
>
> Actual result:
> * Both terminal 1 and terminal 2 display *scratch*

(This bug report unfortunately got no response at the time.)

I can reproduce this behaviour in Emacs 28...

> * 5 seconds later, terminal 1 displays foo.txt prepended with "1;2802;0cd";
> terminal 2 displays *scratch*
>  (this is the opposite of the expected result)

... but not this -- terminal 2 displays foo.txt and terminal 1 displays
*scratch*, so it seems like this bit was fixed, at least.

But the first point still stands -- terminal 2 displays *scratch* first,
and then, one second later, switches to *foo* -- presumably there's
something timing out the `M-x' thing?

Does anybody have any insight into what might be happening here?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no