public inbox for cluster-cvs@sourceware.org
help / color / mirror / Atom feed
From: Lon Hohberger <lon@fedoraproject.org>
To: cluster-cvs-relay@redhat.com
Subject: cluster: RHEL4 - rgmanager: fix netfsclient cache handling
Date: Thu, 18 Jun 2009 17:52:00 -0000	[thread overview]
Message-ID: <20090618175156.71CAD120194@lists.fedorahosted.org> (raw)

Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=175f79e2ad1bac0bdb233eae32f55b8010973813
Commit:        175f79e2ad1bac0bdb233eae32f55b8010973813
Parent:        69249ff719a7f3ee2a6addbdcd2d31fc2a0c1ee1
Author:        Juanjo Villaplana <villapla@si.uji.es>
AuthorDate:    Thu Feb 26 10:33:34 2009 -0500
Committer:     Lon Hohberger <lhh@redhat.com>
CommitterDate: Thu Jun 18 13:51:35 2009 -0400

rgmanager: fix netfsclient cache handling

Ensures correct removal of temporary file when client
caching is disabled.

Resolves: rhbz506152

Signed-off-by: Lon Hohberger <lhh@redhat.com>
---
 rgmanager/src/resources/nfsclient.sh |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/rgmanager/src/resources/nfsclient.sh b/rgmanager/src/resources/nfsclient.sh
index 70e69f1..7e8104a 100755
--- a/rgmanager/src/resources/nfsclient.sh
+++ b/rgmanager/src/resources/nfsclient.sh
@@ -413,13 +413,13 @@ status|monitor)
 	rv=$? 
 
 	if [ $rv -eq 0 ]; then
-		[ -z "$OCF_RESKEY_service_name" ] && rm -f $tmpfn
+		[ "$OCF_RESKEY_use_cache" = "1" ] || rm -f $tmpfn
 		exit 0
 	fi
 
 	declare OCF_RESKEY_target_tmp=$(clufindhostname -i "$OCF_RESKEY_target")
 	if [ $? -ne 0 ]; then
-		[ -z "$OCF_RESKEY_service_name" ] && rm -f $tmpfn
+		[ "$OCF_RESKEY_use_cache" = "1" ] || rm -f $tmpfn
 		ocf_log err "nfsclient:$OCF_RESKEY_name is missing!"
 		exit 1
 	fi
@@ -428,7 +428,7 @@ status|monitor)
 		"^${OCF_RESKEY_path}[\t ]*.*${OCF_RESKEY_target_tmp}" 
 	rv=$? 
 
-	[ -z "$OCF_RESKEY_service_name" ] && rm -f $tmpfn
+	[ "$OCF_RESKEY_use_cache" = "1" ] || rm -f $tmpfn
 	if [ $rv -eq 0 ]; then
 		exit 0
 	fi


                 reply	other threads:[~2009-06-18 17:52 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090618175156.71CAD120194@lists.fedorahosted.org \
    --to=lon@fedoraproject.org \
    --cc=cluster-cvs-relay@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).