From patchwork Thu Sep 8 20:53:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markos Chandras X-Patchwork-Id: 667791 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from archives.nicira.com (archives.nicira.com [96.126.127.54]) by ozlabs.org (Postfix) with ESMTP id 3sVXcJ4S0Lz9s4x for ; Fri, 9 Sep 2016 06:53:36 +1000 (AEST) Received: from archives.nicira.com (localhost [127.0.0.1]) by archives.nicira.com (Postfix) with ESMTP id 577DE10551; Thu, 8 Sep 2016 13:53:35 -0700 (PDT) X-Original-To: dev@openvswitch.org Delivered-To: dev@openvswitch.org Received: from mx3v3.cudamail.com (mx3.cudamail.com [64.34.241.5]) by archives.nicira.com (Postfix) with ESMTPS id 379171054F for ; Thu, 8 Sep 2016 13:53:34 -0700 (PDT) Received: from bar6.cudamail.com (localhost [127.0.0.1]) by mx3v3.cudamail.com (Postfix) with ESMTPS id 9F10D161EFA for ; Thu, 8 Sep 2016 14:53:33 -0600 (MDT) X-ASG-Debug-ID: 1473368012-0b32374f832b160001-byXFYA Received: from mx1-pf1.cudamail.com ([192.168.24.1]) by bar6.cudamail.com with ESMTP id 3TytACmfEGZQbG5E (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Thu, 08 Sep 2016 14:53:32 -0600 (MDT) X-Barracuda-Envelope-From: mchandras@suse.de X-Barracuda-RBL-Trusted-Forwarder: 192.168.24.1 Received: from unknown (HELO mx2.suse.de) (195.135.220.15) by mx1-pf1.cudamail.com with ESMTPS (DHE-RSA-AES256-SHA encrypted); 8 Sep 2016 20:53:31 -0000 Received-SPF: pass (mx1-pf1.cudamail.com: SPF record at suse.de designates 195.135.220.15 as permitted sender) X-Barracuda-Apparent-Source-IP: 195.135.220.15 X-Barracuda-RBL-IP: 195.135.220.15 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 2545AABDE for ; Thu, 8 Sep 2016 20:53:29 +0000 (UTC) X-CudaMail-Envelope-Sender: mchandras@suse.de From: Markos Chandras To: dev@openvswitch.org X-CudaMail-MID: CM-E1-907074913 X-CudaMail-DTE: 090816 X-CudaMail-Originating-IP: 195.135.220.15 Date: Thu, 8 Sep 2016 21:53:22 +0100 X-ASG-Orig-Subj: [##CM-E1-907074913##][PATCH] utilities: ovs-lib: Signal start_daemon failures Message-Id: <20160908205322.19774-1-mchandras@suse.de> X-Mailer: git-send-email 2.10.0 X-Barracuda-Connect: UNKNOWN[192.168.24.1] X-Barracuda-Start-Time: 1473368012 X-Barracuda-Encrypted: ECDHE-RSA-AES256-GCM-SHA384 X-Barracuda-URL: https://web.cudamail.com:443/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at cudamail.com X-Barracuda-BRTS-Status: 1 X-Barracuda-Spam-Score: 0.60 X-Barracuda-Spam-Status: No, SCORE=0.60 using global scores of TAG_LEVEL=3.5 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=4.0 tests=BSF_SC5_MJ1963, RDNS_NONE X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.32740 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- 0.10 RDNS_NONE Delivered to trusted network by a host with no rDNS 0.50 BSF_SC5_MJ1963 Custom Rule MJ1963 Subject: [ovs-dev] [PATCH] utilities: ovs-lib: Signal start_daemon failures X-BeenThere: dev@openvswitch.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dev-bounces@openvswitch.org Sender: "dev" Make sure we communicate failures to the caller when start_daemon fails to start a process as the caller may not be able to proceed after this. Signed-off-by: Markos Chandras --- utilities/ovs-lib.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utilities/ovs-lib.in b/utilities/ovs-lib.in index 773efb3..6fd861e 100644 --- a/utilities/ovs-lib.in +++ b/utilities/ovs-lib.in @@ -190,7 +190,7 @@ start_daemon () { set nice -n "$priority" "$@" fi - action "Starting $daemon" "$@" + action "Starting $daemon" "$@" || return 1 if test X"$strace" != X; then # Strace doesn't have the -D option so we attach after the fact.