cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
* [Cluster-devel] Cluster Project branch, master, updated. cluster-2.99.05-49-gc418d29
@ 2008-07-03 16:16 teigland
  2008-07-03 18:24 ` Fabio M. Di Nitto
  0 siblings, 1 reply; 2+ messages in thread
From: teigland @ 2008-07-03 16:16 UTC (permalink / raw)
  To: cluster-devel.redhat.com

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Cluster Project".

http://sources.redhat.com/git/gitweb.cgi?p=cluster.git;a=commitdiff;h=c418d299d477fe52359022796c9336f1ef862cc8

The branch, master has been updated
       via  c418d299d477fe52359022796c9336f1ef862cc8 (commit)
      from  5f25fbd0791fa5d2089601698d3733fc6ec58622 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit c418d299d477fe52359022796c9336f1ef862cc8
Author: David Teigland <teigland@redhat.com>
Date:   Thu Jul 3 11:11:29 2008 -0500

    fence_node: use simple logsys api
    
    instead of the macros.
    
    Signed-off-by: David Teigland <teigland@redhat.com>

-----------------------------------------------------------------------

Summary of changes:
 fence/fence_node/fence_node.c |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/fence/fence_node/fence_node.c b/fence/fence_node/fence_node.c
index d64066a..508aa97 100644
--- a/fence/fence_node/fence_node.c
+++ b/fence/fence_node/fence_node.c
@@ -22,13 +22,6 @@ while (0)
 
 static char *prog_name;
 
-LOGSYS_DECLARE_SYSTEM (NULL,
-	LOG_MODE_OUTPUT_STDERR | LOG_MODE_OUTPUT_SYSLOG_THREADED,
-	NULL,
-	SYSLOGFACILITY);
-
-LOGSYS_DECLARE_SUBSYS ("FENCE_NODE", SYSLOGLEVEL);
-
 static void print_usage(void)
 {
 	printf("Usage:\n");
@@ -44,7 +37,7 @@ static void print_usage(void)
 
 int main(int argc, char *argv[])
 {
-	int cont = 1, optchar, error;
+	int cont = 1, optchar, error, rv;
 	char *victim = NULL;
 
 	prog_name = argv[0];
@@ -92,11 +85,15 @@ int main(int argc, char *argv[])
 	if (!victim)
 		die("no node name specified");
 
+	logsys_init("fence_node",
+		    LOG_MODE_OUTPUT_STDERR | LOG_MODE_OUTPUT_SYSLOG_THREADED,
+		    SYSLOGFACILITY, LOG_LEVEL_NOTICE, NULL);
+
 	error = fence_node(victim);
 
 	if (error) {
 		log_printf(LOG_ERR, "Fence of \"%s\" was unsuccessful\n", victim);
-		exit(EXIT_FAILURE);
+		rv = EXIT_FAILURE;
 	} else {
 		log_printf(LOG_NOTICE, "Fence of \"%s\" was successful\n", victim);
 
@@ -104,7 +101,10 @@ int main(int argc, char *argv[])
 		   this node again if the fence_node() rebooted it. */
 		fenced_external(victim);
 
-		exit(EXIT_SUCCESS);
+		rv = EXIT_SUCCESS;
 	}
+
+	logsys_exit();
+	exit(rv);
 }
 


hooks/post-receive
--
Cluster Project



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [Cluster-devel] Cluster Project branch, master, updated. cluster-2.99.05-49-gc418d29
  2008-07-03 16:16 [Cluster-devel] Cluster Project branch, master, updated. cluster-2.99.05-49-gc418d29 teigland
@ 2008-07-03 18:24 ` Fabio M. Di Nitto
  0 siblings, 0 replies; 2+ messages in thread
From: Fabio M. Di Nitto @ 2008-07-03 18:24 UTC (permalink / raw)
  To: cluster-devel.redhat.com

On Thu, 3 Jul 2008, teigland at sourceware.org wrote:

> -LOGSYS_DECLARE_SUBSYS ("FENCE_NODE", SYSLOGLEVEL);

same thing here about SYSLOGLEVEL

> +	logsys_init("fence_node",
> +		    LOG_MODE_OUTPUT_STDERR | LOG_MODE_OUTPUT_SYSLOG_THREADED,
> +		    SYSLOGFACILITY, LOG_LEVEL_NOTICE, NULL);
> +

s/LOG_LEVEL_NOTICE/SYSLOGLEVEL

Fabio

--
I'm going to make him an offer he can't refuse.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-07-03 18:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-03 16:16 [Cluster-devel] Cluster Project branch, master, updated. cluster-2.99.05-49-gc418d29 teigland
2008-07-03 18:24 ` Fabio M. Di Nitto

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 NNTP newsgroup(s).