Subject: bug#63865: 29.0.90; call-process while owning the X selection hangs other processes

From: Eli Zaretskii <[email-masked]>
Date: Sat, 03 Jun 2023 14:16:13 +0300

> From: Spencer Baugh <[email-masked]>
> Cc: Eli Zaretskii <[email-masked]>,  [email-masked]
> Date: Sat, 03 Jun 2023 07:10:41 -0400
> 
> BTW, this can also be reproduced using just Emacs.  If I try to paste in
> another Emacs instead of in Google Chrome, I get a hang, followed by:
> 
> gui-get-selection: (error "Timed out waiting for reply from selection owner")

Isn't this exactly what is expected to happen in this case?  Po Lu
said, in response to my question:

> > It is strange that you cannot reproduce this.  I thought that when
> > another application requests a selection or clipboard text, the owner
> > (Emacs in this case) gets called, and since Emacs is sleeping, we
> > won't respond.
> >
> > Are there some other factors involved in this interaction that I'm
> > missing?
> 
> In this case, the requestor should time out and give up (which is what I
> see.)  It should not simply freeze.

And that is exactly what happens when Emacs requests the selection: it
times out.  What else did you expect?