summaryrefslogtreecommitdiff
path: root/lib/Vyatta
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2009-03-02 17:05:33 -0800
committerStephen Hemminger <stephen.hemminger@vyatta.com>2009-03-02 17:05:33 -0800
commit5f7d237822a7d430d7afa58cbb6339642cf3ab76 (patch)
treed09b0f0d8309ba9f8722a51d45e8f358a2c8cc4e /lib/Vyatta
parent2840eb48231ca4fccfa49436002f968c0ef0e3c8 (diff)
downloadvyatta-cfg-5f7d237822a7d430d7afa58cbb6339642cf3ab76.tar.gz
vyatta-cfg-5f7d237822a7d430d7afa58cbb6339642cf3ab76.zip
Ignore /sys/class/net/bonding_masters
Bonding leaves this file in /sys/class/net that confuses scripts.
Diffstat (limited to 'lib/Vyatta')
-rwxr-xr-xlib/Vyatta/Misc.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Vyatta/Misc.pm b/lib/Vyatta/Misc.pm
index 9140d4c..1565765 100755
--- a/lib/Vyatta/Misc.pm
+++ b/lib/Vyatta/Misc.pm
@@ -93,7 +93,8 @@ sub generate_dhclient_intf_files {
sub getInterfaces {
opendir (my $sys_class, '/sys/class/net')
or die "can't open /sys/class/net: $!";
- my @interfaces = grep !/^\./, readdir $sys_class;
+ my @interfaces =
+ grep { ( !/^\./ ) && ( $_ ne 'bonding_masters' ) } readdir $sys_class;
closedir $sys_class;
return @interfaces;
}