GNU bug report logs -
#31901
Incorrect make-network-process + nowait state handling for non-existing unix sockets in emacs-26.1
Previous Next
Reported by: Mike Kazantsev <mk.fraggod <at> gmail.com>
Date: Tue, 19 Jun 2018 13:40:02 UTC
Severity: normal
Tags: confirmed, fixed
Fixed in version 26.2
Done: Noam Postavsky <npostavs <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
On Sun, 22 Jul 2018 13:40:51 +0200
Lars Ingebrigtsen <larsi <at> gnus.org> wrote:
> OK, I've now fixed the async error case (on master), I think:
>
> (process-live-p socket)
> nil
> (process-status socket)
> file-missing
>
> I've fixed this on master, because I'm not 100% sure that my fix is
> completely correct. Should we perhaps also call a sentinel in the async
> error case?
Unless I misunderstood the question, for me as a user, it would be more
obvious to get this error in a sentinel call than not with emacs 26,
because that's how :nowait is documented to work now:
The recommended way to deal with asynchronous sockets is to avoid
interacting with them until they have changed status to "run".
This is most easily done from a process sentinel.
https://github.com/emacs-mirror/emacs/blob/master/etc/NEWS.26
If bool is non-nil for a stream connection, return without waiting
for the connection to complete. When the connection succeeds or
fails, Emacs will call the sentinel function, with a second argument
matching "open" (if successful) or "failed".
https://www.gnu.org/software/emacs/manual/html_node/elisp/Network-Processes.html
Given either of these guidelines, it'd be more surprising to not get
error state in the sentinel call with ":nowait t" in emacs-26.
(while ":nowait nil" signaling 'file-error is kinda expected)
--
Mike Kazantsev // fraggod.net
This bug report was last modified 6 years and 289 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.