From 1381cf38686885fb5f28ed1589412237c9bf636d Mon Sep 17 00:00:00 2001 From: K3PGM Date: Sun, 14 Mar 2021 21:35:10 -0400 Subject: [PATCH] Fix for uci_set_indexed_option() inserting multiple empty sections (#78) --- files/www/cgi-bin/ucifunc.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/www/cgi-bin/ucifunc.pm b/files/www/cgi-bin/ucifunc.pm index bb346b2d..7032e717 100644 --- a/files/www/cgi-bin/ucifunc.pm +++ b/files/www/cgi-bin/ucifunc.pm @@ -38,7 +38,7 @@ sub uci_get_sectiontype_count() { my ($config, $stype)=@_; - my $cmd=sprintf('uci show %s|egrep %s\.\@%s.*=%s|wc -l',$config,$stype,$stype,$stype); + my $cmd=sprintf('uci show %s|egrep %s\.\@%s.*=%s|wc -l',$config,$config,$stype,$stype); my $res=`$cmd`; my $rc=$?; chomp($res);