GNU bug report logs - #56488
process/thread interaction causes infinite hang in url-copy-file

Previous Next

Package: emacs;

Reported by: Tom Gillespie <tgbugs <at> gmail.com>

Date: Sun, 10 Jul 2022 21:27:01 UTC

Severity: normal

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Tom Gillespie <tgbugs <at> gmail.com>
To: Emacs Bug Report <bug-gnu-emacs <at> gnu.org>
Subject: process/thread interaction causes infinite hang in url-copy-file
Date: Sun, 10 Jul 2022 14:26:08 -0700
[Message part 1 (text/plain, inline)]
This is a bug that appears to be caused by calling set-process-thread
on some process, allowing that process to finish and be cleaned up, and
then trying to wait on some other process called at a later point.

While the issue appears when calling url-copy-file, I suspect that
other functions that create a process and then wait for the result are
affected, but I have not identified any at this point in time.

I have attached process-thread-bugs.el that was also included in
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=56487 which includes
the repro for this issue.

The two functions of interest are enable-hang and maybe-trigger-hang.

Assuming process-thread-bugs.el is in the top level of the emacs repo
run the following commands to see the behavior in action

src/emacs -Q -batch -l ./process-thread-bugs.el wont hang 1

src/emacs -Q -batch -l ./process-thread-bugs.el will hang 1

src/emacs -Q -batch -l ./process-thread-bugs.el will hang 2

When calling will hang 1 or will hang 2, the behavior should be
obvious as a presumably infinite number of lines of "oh no" being
printed to stderr.
[process-thread-bugs.el (text/x-emacs-lisp, attachment)]

This bug report was last modified 2 years and 346 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.