From 9f81e7e0e83f71277b2163889889be4905a6f22a Mon Sep 17 00:00:00 2001 From: Robert Bays Date: Fri, 19 Nov 2010 11:33:41 -0800 Subject: update to use getIP --- scripts/bgp/vyatta-bgp.pl | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'scripts/bgp/vyatta-bgp.pl') diff --git a/scripts/bgp/vyatta-bgp.pl b/scripts/bgp/vyatta-bgp.pl index 2b623bc0..20c248b5 100755 --- a/scripts/bgp/vyatta-bgp.pl +++ b/scripts/bgp/vyatta-bgp.pl @@ -1075,8 +1075,7 @@ sub check_neighbor_ip { my $neighbor = shift; my $local_ips; - $local_ips = `ip addr | grep inet`; - $local_ips =~ s/\s+inet(6*)\s(\S+)\/.+/$2 /g; + $local_ips = join( ' ', getIP() ); if ($local_ips =~ /$neighbor/g) { die "Can't set neighbor address to local system IP.\n"; -- cgit v1.2.3