This is the mail archive of the
cluster-cvs@sourceware.org
mailing list for the cluster.
cluster: STABLE3 - fenced: avoid static warnings
- From: David Teigland <teigland at fedoraproject dot org>
- To: cluster-cvs-relay at redhat dot com
- Date: Mon, 11 May 2009 15:17:33 +0000 (UTC)
- Subject: cluster: STABLE3 - fenced: avoid static warnings
Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=160d8dea8b9dae39f80cd79f3b716b346d571204
Commit: 160d8dea8b9dae39f80cd79f3b716b346d571204
Parent: 0bee5b75ac8c6c8dfbf55e3dcd1c6fb70a505fe6
Author: David Teigland <teigland@redhat.com>
AuthorDate: Mon May 11 10:09:56 2009 -0500
Committer: David Teigland <teigland@redhat.com>
CommitterDate: Mon May 11 10:09:56 2009 -0500
fenced: avoid static warnings
By using a variable "default" string instead of a static one.
Signed-off-by: David Teigland <teigland@redhat.com>
---
fence/fenced/main.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/fence/fenced/main.c b/fence/fenced/main.c
index 9600129..c1d96de 100644
--- a/fence/fenced/main.c
+++ b/fence/fenced/main.c
@@ -423,9 +423,12 @@ static void query_domain_nodes(int f, int option, int max)
static void process_connection(int ci)
{
struct fenced_header h;
+ char default_name[8];
char *extra = NULL;
int rv, extra_len;
+ strcpy(default_name, "default");
+
rv = do_read(client[ci].fd, &h, sizeof(h));
if (rv < 0) {
log_debug("connection %d read error %d", ci, rv);
@@ -460,13 +463,13 @@ static void process_connection(int ci)
switch (h.command) {
case FENCED_CMD_JOIN:
- do_join("default");
+ do_join(default_name);
break;
case FENCED_CMD_LEAVE:
- do_leave("default");
+ do_leave(default_name);
break;
case FENCED_CMD_EXTERNAL:
- do_external("default", extra, extra_len);
+ do_external(default_name, extra, extra_len);
break;
case FENCED_CMD_DUMP_DEBUG:
case FENCED_CMD_NODE_INFO: