From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tremer To: development@lists.ipfire.org Subject: Re: [PATCH v3 8/8] wlanap.cgi: Access db.txt in place of using regdbdump on regulatory.bin Date: Thu, 05 Aug 2021 22:31:13 +0200 Message-ID: In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1041643314990653004==" List-Id: --===============1041643314990653004== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hello, > On 5 Aug 2021, at 12:55, Adolf Belka wrote: >=20 > Hi Bernhard, >=20 > On 05/08/2021 12:40, Bernhard Bitsch wrote: >> Reviewed-by: Bernhard Bitsch >> Tested-by: Bernhard Bitsch >> Am 05.08.2021 um 12:21 schrieb Adolf Belka: >>> - wlanap.cgi was using regdbdump from crda to create a text based list of= the >>> wireless settings by country database. >>> - With the removal of crda as part of the removal of python2 this option = could not be >>> used. >>> - wireless-regdb also has a text based database list in the source tarbal= l and this >>> patch makes wlanap.cgi read this list into the @countrylist_cmd varia= ble >>> - This needs to be tested by someone that has an IPFire system with wifi = that can access >>> and evaluate wlanap.cgi to confirm that this change functions as expe= cted. >>> - This version changes the name of the stored text file from db.txt to re= gulatorydb.txt >>> - The command to read the data from regulatorydb.txt into @countrylist_cm= d has been >>> corrected >>>=20 >>> Signed-off-by: Adolf Belka >>> --- >>> html/cgi-bin/wlanap.cgi | 5 ++++- >>> 1 file changed, 4 insertions(+), 1 deletion(-) >>>=20 >>> diff --git a/html/cgi-bin/wlanap.cgi b/html/cgi-bin/wlanap.cgi >>> index eba5fe774..3024257db 100644 >>> --- a/html/cgi-bin/wlanap.cgi >>> +++ b/html/cgi-bin/wlanap.cgi >>> @@ -312,8 +312,11 @@ if ( $channel =3D~ /\d+/ ){push(@temp,$channel + 0);} >>> push(@channellist, @temp); >>> } >>> -my @countrylist_cmd =3D `regdbdump /usr/lib/crda/regulatory.bin 2>/dev/n= ull`; >>> # get available country codes >>> +open(FILE, =E2=80=9C> Should read: >> +open(FILE, =E2=80=9C Thanks so much for spotting this. The power of the review process. I will r= e-issue the patches. Exactly :) Great work everyone! >=20 > Regards, > Adolf. >> > +my @countrylist_cmd =3D ; >>> +close(FILE); >>> + >>> my @temp =3D "00"; >>> foreach (@countrylist_cmd){ --===============1041643314990653004==--