Fix a logig bug in _status_down() that prevented fallback servers
from being removed if
a) at start no other real servers were present and
b) a real server was subsequently added
The new logic is the logical not of that found in _status_up
With thanks to Sebastian Vieira
Signed-off-by: Simon Horman <[EMAIL PROTECTED]>
Index: heartbeat/ldirectord/ldirectord.in
===================================================================
--- heartbeat.orig/ldirectord/ldirectord.in 2007-07-04 17:20:12.000000000
+0900
+++ heartbeat/ldirectord/ldirectord.in 2007-07-04 18:08:53.000000000 +0900
@@ -3121,9 +3121,9 @@ sub _status_down
my $real_id = get_real_id_str($r, $v);
if (defined($is_fallback)) {
- if (! defined($v->{real_status}) or
- ! defined($v->{fallback_status}) or
- ! $v->{fallback_status}->{"$real_id"}) {
+ if (! defined($v->{real_status}) and
+ (! defined($v->{fallback_status}) or
+ !$v->{fallback_status}->{"$real_id"})) {
return undef;
}
}
--
--
Horms
H: http://www.vergenet.net/~horms/
W: http://www.valinux.co.jp/en/
_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/