diff options
-rwxr-xr-x | lib/Vyatta/Keepalived.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Vyatta/Keepalived.pm b/lib/Vyatta/Keepalived.pm index 3d8fe24..fb575a1 100755 --- a/lib/Vyatta/Keepalived.pm +++ b/lib/Vyatta/Keepalived.pm @@ -197,7 +197,8 @@ sub vrrp_get_config { $path = $interface->path(); $config->setLevel($path); - my $primary_addr = $config->returnOrigValue("address"); + my @addr = getIP($intf, 4); + my $primary_addr = shift @addr; if (!defined $primary_addr) { $primary_addr = "0.0.0.0"; } |