[nagiosplug] check_dhcp: fix tests interface detection
Nagios Plugin Development
nagios-plugins at users.sourceforge.net
Tue Sep 17 23:40:24 CEST 2013
Module: nagiosplug
Branch: master
Commit: 08d554ada1d12a0a0bc9c2e6e218789e05287af8
Author: Sven Nierlein <Sven.Nierlein at consol.de>
Committer: Sven Nierlein <sven at consol.de>
Date: Tue Sep 17 13:13:26 2013 +0200
URL: http://nagiosplug.git.sf.net/git/gitweb.cgi?p=nagiosplug/nagiosplug;a=commit;h=08d554a
check_dhcp: fix tests interface detection
---
plugins-root/t/check_dhcp.t | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/plugins-root/t/check_dhcp.t b/plugins-root/t/check_dhcp.t
index 555523a..222f454 100644
--- a/plugins-root/t/check_dhcp.t
+++ b/plugins-root/t/check_dhcp.t
@@ -36,7 +36,7 @@ my $hostname_invalid = getTestParameter( "NP_HOSTNAME_INVALID",
# try to determince interface
my $interface = '';
-if(`ifconfig -a 2>/dev/null` =~ m/^(e(m|th)\d+)/mx and $1 ne 'eth0') {
+if(`ifconfig -a 2>/dev/null` =~ m/^(e\w*\d+)/mx and $1 ne 'eth0') {
$interface = ' -i '.$1;
}
More information about the Commits
mailing list