summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2008-09-23 16:41:16 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2008-09-23 16:41:16 -0700
commit0558e3ce00df57792cef3678f21fa6cd834ce641 (patch)
treedb29b26b42f17fab3f161ad2f3ad402dfc397652
parent5a2549a7bc30dfcaf1b8e9c3cedf68bd470a717f (diff)
parentbab23d7cb8291192c74519f7cca2ee0044992723 (diff)
downloadvyatta-cfg-system-0558e3ce00df57792cef3678f21fa6cd834ce641.tar.gz
vyatta-cfg-system-0558e3ce00df57792cef3678f21fa6cd834ce641.zip
Merge branch 'islavista' of suva.vyatta.com:/git/vyatta-cfg-system into islavista
-rw-r--r--scripts/dns-forwarding/vyatta-dns-forwarding.pl4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/dns-forwarding/vyatta-dns-forwarding.pl b/scripts/dns-forwarding/vyatta-dns-forwarding.pl
index 4a011b6a..38f5ee67 100644
--- a/scripts/dns-forwarding/vyatta-dns-forwarding.pl
+++ b/scripts/dns-forwarding/vyatta-dns-forwarding.pl
@@ -119,7 +119,7 @@ sub dnsforwarding_get_values {
if (@use_dhcp_nameservers != 0) {
$use_dnsmasq_conf = 1;
foreach my $interface (@use_dhcp_nameservers) {
- my $dhcp_nameserver_count=`grep nameserver /etc/resolv.conf.dhclient-new-$interface | wc -l`;
+ my $dhcp_nameserver_count=`grep nameserver /etc/resolv.conf.dhclient-new-$interface 2>/dev/null | wc -l`;
if ($dhcp_nameserver_count > 0) {
my @dhcp_nameservers = `grep nameserver /etc/resolv.conf.dhclient-new-$interface`;
for my $each_nameserver (@dhcp_nameservers) {
@@ -149,7 +149,7 @@ sub dnsforwarding_write_file {
sub check_nameserver {
- my $cmd = `grep nameserver /etc/resolv.conf|wc -l`;
+ my $cmd = `grep nameserver /etc/resolv.conf 2>/dev/null | wc -l`;
return $cmd;
}