From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Wolfgang Schnerring Newsgroups: gmane.emacs.bugs Subject: bug#6963: More usecases, patch attached Date: Wed, 29 Sep 2010 17:08:05 +0200 Message-ID: <20100929150805.GA6325@elzar.ws.whq.gocept.com> References: <201009011216.17097.arne_bab@web.de> <20100929060918.GB9654@elzar.ws.whq.gocept.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1285773122 2876 80.91.229.12 (29 Sep 2010 15:12:02 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 29 Sep 2010 15:12:02 +0000 (UTC) To: 6963@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 29 17:12:01 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P0yK7-00070q-2v for geb-bug-gnu-emacs@m.gmane.org; Wed, 29 Sep 2010 17:11:59 +0200 Original-Received: from localhost ([127.0.0.1]:52258 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P0yK6-0002Zp-7n for geb-bug-gnu-emacs@m.gmane.org; Wed, 29 Sep 2010 11:11:58 -0400 Original-Received: from [140.186.70.92] (port=42932 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P0yJm-0002Q7-3a for bug-gnu-emacs@gnu.org; Wed, 29 Sep 2010 11:11:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1P0yJd-0001u6-0H for bug-gnu-emacs@gnu.org; Wed, 29 Sep 2010 11:11:37 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50514) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P0yJc-0001u2-V8 for bug-gnu-emacs@gnu.org; Wed, 29 Sep 2010 11:11:28 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1P0yEM-0005Rd-Bb; Wed, 29 Sep 2010 11:06:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Wolfgang Schnerring Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 29 Sep 2010 15:06:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6963 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 6963-submit@debbugs.gnu.org id=B6963.128577272220919 (code B ref 6963); Wed, 29 Sep 2010 15:06:02 +0000 Original-Received: (at 6963) by debbugs.gnu.org; 29 Sep 2010 15:05:22 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P0yDh-0005RM-2u for submit@debbugs.gnu.org; Wed, 29 Sep 2010 11:05:21 -0400 Original-Received: from pharos.wosc.de ([85.214.124.141]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1P0yDf-0005RH-GU for 6963@debbugs.gnu.org; Wed, 29 Sep 2010 11:05:20 -0400 Original-Received: from hlle-4db837f5.pool.mediaways.net ([77.184.55.245] helo=elzar.ws.whq.gocept.com) by pharos.wosc.de with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1P0yGL-0008LE-Hd for 6963@debbugs.gnu.org; Wed, 29 Sep 2010 17:08:05 +0200 Original-Received: from wosc by elzar.ws.whq.gocept.com with local (Exim 4.72) (envelope-from ) id 1P0yGL-0002Dd-JA for 6963@debbugs.gnu.org; Wed, 29 Sep 2010 17:08:05 +0200 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Wed, 29 Sep 2010 11:06:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:40543 Archived-At: * Juanma Barranquero [2010-09-29 16:42]: > On Wed, Sep 29, 2010 at 08:09, Wolfgang Schnerring 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