cluster: master - cman: prevent accidents with cman_tool expected
Christine Caulfield
chrissie@fedoraproject.org
Thu Jan 29 14:28:00 GMT 2009
Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=684e8533f7a6e360d519382a312fe76b9dff8511
Commit: 684e8533f7a6e360d519382a312fe76b9dff8511
Parent: a1620c2b08020ec676f4e0ab451f627393124142
Author: Christine Caulfield <ccaulfie@redhat.com>
AuthorDate: Thu Jan 29 14:28:08 2009 +0000
Committer: Christine Caulfield <ccaulfie@redhat.com>
CommitterDate: Thu Jan 29 14:28:08 2009 +0000
cman: prevent accidents with cman_tool expected
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
---
cman/cman_tool/main.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/cman/cman_tool/main.c b/cman/cman_tool/main.c
index 7f6dc6c..ef71eca 100644
--- a/cman/cman_tool/main.c
+++ b/cman/cman_tool/main.c
@@ -532,6 +532,10 @@ static void set_expected(commandline_t *comline)
cman_handle_t h;
int result;
+ if (comline->expected_votes == 0) {
+ die("expected_votes not specified");
+ }
+
h = open_cman_handle(1);
if ((result = cman_set_expected_votes(h, comline->expected_votes)))
More information about the Cluster-cvs
mailing list