Skip to contentSkip to conversation

conga/ricci/modules/cluster Clusvcadm.cpp

Cluster-devel [email protected] 1 participant 1 message Mar 12, 2007

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/cluster
Module name: conga
Changes by: rmccabe at sourceware.org 2007-03-12 03:45:19

Modified files:
ricci/modules/cluster: Clusvcadm.cpp

Log message:
Fix a bug that caused service relocation to fail.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/ricci/modules/cluster/Clusvcadm.cpp.diff?cvsroot=cluster&r1=1.11&r2=1.12

ricci/modules/cluster/Clusvcadm.cpp +5 -5
@@ -108,9 +108,8 @@
 	  iter->status == ServiceStatus::RG_STATE_DISABLED)
 	flag = "-e";
       else if (iter->status == ServiceStatus::RG_STATE_STARTED ||
-	       iter->status == ServiceStatus::RG_STATE_STARTING) {
-	} else
-	  flag = "-r";
+	       iter->status == ServiceStatus::RG_STATE_STARTING)
+	flag = "-r";
       
       if (flag.size()) {
 	String out, err;
@@ -170,9 +169,8 @@
 	  iter->status == ServiceStatus::RG_STATE_DISABLED)
 	flag = "-e";
       else if (iter->status == ServiceStatus::RG_STATE_STARTED ||
-	       iter->status == ServiceStatus::RG_STATE_STARTING) {
+	       iter->status == ServiceStatus::RG_STATE_STARTING)
 	flag = "-M";
-      }
       
       if (flag.size()) {
 	String out, err;
@@ -242,6 +240,8 @@
       String flag;
       if (iter->status == ServiceStatus::RG_STATE_MIGRATE)
          throw String(servicename + " is in the process of being migrated");
+      if (iter->status == ServiceStatus::RG_STATE_STARTING)
+         throw String(servicename + " is in the process of being started");
 
       if (iter->status == ServiceStatus::RG_STATE_STOPPED ||
 	  iter->status == ServiceStatus::RG_STATE_STOPPING ||