cluster: STABLE3 - Fix open flags so that logfile won't be truncated each time we open it.

rohara rohara at fedoraproject.org
Mon Jun 28 21:04:13 UTC 2010


Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=65a0fb947f3b6ca626fd6a75e05dffe786fe6747
Commit:        65a0fb947f3b6ca626fd6a75e05dffe786fe6747
Parent:        49d1ad101092e05efa2346917f3f0907ffdd3f28
Author:        Ryan O'Hara <rohara at redhat.com>
AuthorDate:    Mon Jun 28 15:59:27 2010 -0500
Committer:     Ryan O'Hara <rohara at redhat.com>
CommitterDate: Mon Jun 28 16:03:45 2010 -0500

Fix open flags so that logfile won't be truncated each time we open it.

rhbz#608887

Signed-off-by: Ryan O'Hara <rohara at redhat.com>
---
 fence/agents/scsi/fence_scsi.pl |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fence/agents/scsi/fence_scsi.pl b/fence/agents/scsi/fence_scsi.pl
index 59259cf..992a3eb 100644
--- a/fence/agents/scsi/fence_scsi.pl
+++ b/fence/agents/scsi/fence_scsi.pl
@@ -583,7 +583,7 @@ else {
 ## and redirect STDOUT and STDERR to the logfile.
 ##
 if (defined $opt_f) {
-    open (LOG, ">$opt_f") or die "$!\n";
+    open (LOG, >">$opt_f") or die "$!\n";
     open (STDOUT, ">&LOG");
     open (STDERR, ">&LOG");
 }


More information about the cluster-commits mailing list