From bf80091d1e682b6ddb4b934b3cfd22ce0c03149f Mon Sep 17 00:00:00 2001 From: Stefan Schantl Date: Thu, 20 May 2021 20:31:33 +0200 Subject: [PATCH] netexternal.cgi: Grab DNS servers in pure perl Signed-off-by: Stefan Schantl --- html/cgi-bin/netexternal.cgi | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/html/cgi-bin/netexternal.cgi b/html/cgi-bin/netexternal.cgi index a31502dd0c..1e3760c2b3 100644 --- a/html/cgi-bin/netexternal.cgi +++ b/html/cgi-bin/netexternal.cgi @@ -86,8 +86,7 @@ if ( $querry[0] ne~ ""){ &General::readhash("${General::swroot}/dhcpc/dhcpcd-$netsettings{'RED_DEV'}.info", \%dhcpinfo); - my $DNS1=`echo $dhcpinfo{'domain_name_servers'} | cut -f 1 -d " "`; - my $DNS2=`echo $dhcpinfo{'domain_name_servers'} | cut -f 2 -d " "`; + my ($DNS1, $DNS2) = split(/ /, $dhcpinfo{'domain_name_servers'}); my $lsetme=0; my $leasetime=""; -- 2.39.5