Просмотр исходного кода

totemsrp: Fix typo with cont gather

Patch f3ffd3da5c71a10e1783a38e50bafc61192854f6 introduced named states
of state-machine, but sadly contains logical problem causing
stats.continuous_gather increasing even when it shouldn't. Problem is
not critical, because continuous_gather is set to 0 on successful
membership creation.

Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Reviewed-by: Christine Caulfield <ccaulfie@redhat.com>
Jan Friesse 12 лет назад
Родитель
Сommit
38c04d9a66
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      exec/totemsrp.c

+ 1 - 1
exec/totemsrp.c

@@ -2089,7 +2089,7 @@ static void memb_state_gather_enter (
 	instance->memb_state = MEMB_STATE_GATHER;
 	instance->stats.gather_entered++;
 
-	if (TOTEMSRP_GSFROM_THE_CONSENSUS_TIMEOUT_EXPIRED == 3) {
+	if (gather_from == TOTEMSRP_GSFROM_THE_CONSENSUS_TIMEOUT_EXPIRED) {
 		/*
 		 * State 3 means gather, so we are continuously gathering.
 		 */