From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30051 invoked by alias); 12 Mar 2009 21:40:39 -0000 Received: (qmail 30045 invoked by alias); 12 Mar 2009 21:40:38 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS X-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS X-Spam-Check-By: sourceware.org X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on bastion.fedora.phx.redhat.com Subject: cluster: RHEL4 - rgmanager: fix ambiguous output when resource fails to stop To: cluster-cvs-relay@redhat.com X-Project: Cluster Project X-Git-Module: cluster.git X-Git-Refname: refs/heads/RHEL4 X-Git-Reftype: branch X-Git-Oldrev: 46a8552a07c7e72122c9495c74eb97276a31b7bc X-Git-Newrev: 1e89c485ec2de1f91727569ba3230b36b26034d3 From: Lon Hohberger Message-Id: <20090312214014.C848F1201BF@lists.fedorahosted.org> Date: Thu, 12 Mar 2009 21:40:00 -0000 X-Scanned-By: MIMEDefang 2.58 on 172.16.52.254 Mailing-List: contact cluster-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: cluster-cvs-owner@sourceware.org X-SW-Source: 2009-q1/txt/msg00773.txt.bz2 Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=1e89c485ec2de1f91727569ba3230b36b26034d3 Commit: 1e89c485ec2de1f91727569ba3230b36b26034d3 Parent: 46a8552a07c7e72122c9495c74eb97276a31b7bc Author: Lon Hohberger AuthorDate: Mon Mar 2 15:36:00 2009 -0500 Committer: Lon Hohberger CommitterDate: Thu Mar 12 17:40:09 2009 -0400 rgmanager: fix ambiguous output when resource fails to stop https://bugzilla.redhat.com/show_bug.cgi?id=480835 Signed-off-by: Lon Hohberger --- rgmanager/src/daemons/rg_state.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/rgmanager/src/daemons/rg_state.c b/rgmanager/src/daemons/rg_state.c index df0ac1b..c717ecc 100644 --- a/rgmanager/src/daemons/rg_state.c +++ b/rgmanager/src/daemons/rg_state.c @@ -974,7 +974,10 @@ _svc_stop(char *svcName, int req, int recover, uint32_t newstate) } rg_unlock(svcName, lockp); - ret = group_op(svcName, RG_STOP); + if (group_op(svcName, RG_STOP) != 0) + ret = RG_EFAIL; + else + ret = 0; if (old_state == RG_STATE_FAILED && newstate == RG_STATE_DISABLED) { if (ret)