GNU bug report logs -
#6963
Return an exit status to emacsclient
Previous Next
Reported by: Arne Babenhauserheide <arne_bab <at> web.de>
Date: Wed, 1 Sep 2010 10:16:01 UTC
Severity: wishlist
Found in version 23.2
Done: Chong Yidong <cyd <at> stupidchicken.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
* Juanma Barranquero <lekktu <at> gmail.com> [2010-09-29 16:42]:
> On Wed, Sep 29, 2010 at 08:09, Wolfgang Schnerring <wosc <at> wosc.de> wrote:
> > since emacsclient returns 0 no matter what.
> That's not accurate. When emacsclient detects a problem with itself
> (missing server file, error opening socket, etc.) it returns
> EXIT_FAILURE (1). What it currently does not do, however, is returning
> EXIT_FAILURE for errors passed back from Emacs.
Right. Your description is accurate, I was glossing over a bit too
much, sorry.
> - should this be considered a bug, and installed on emacs-23, or a new
> feature, for the trunk?
I personally consider it a bug, since everything else about "errors
from Emacs" is already there, only the exit status is missing. And
that really does not play nice with others.
(That said, this is a gray area, and one could probably also just as
well argue the opposite.)
> - should emacsclient return 1 for these new errors, or a new error
> code (2) to allow distinguishing them?
It probably makes sense to distinguish these, since they are different
types of errors, technical ("communication with Emacs failed") vs.
semantic ("Emacs said boo!").
One might want to invoke something that has known error cases, which
would benefit from being treated differently than a socket error or
somesuch.
Wolfgang
This bug report was last modified 14 years and 276 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.