From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tremer To: location@lists.ipfire.org Subject: Re: [PATCH] location-importer.in: Do not make things more complicated than they are Date: Mon, 20 Dec 2021 17:54:48 +0100 Message-ID: <20697DD1-6F58-4304-90FD-82E21D7A37B5@ipfire.org> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3463480525211469568==" List-Id: --===============3463480525211469568== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Reviewed-by: Michael Tremer > On 18 Dec 2021, at 13:57, Peter M=C3=BCller wr= ote: >=20 > Suggested-by: Michael Tremer > Signed-off-by: Peter M=C3=BCller > --- > src/python/location-importer.in | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/src/python/location-importer.in b/src/python/location-importer= .in > index 118b0de..f39a42b 100644 > --- a/src/python/location-importer.in > +++ b/src/python/location-importer.in > @@ -687,7 +687,7 @@ class CLI(object): > start_address =3D ipaddress.ip_network(start_address, strict=3DFalse) > except ValueError: > start_address =3D start_address.split("/") > - ldigits =3D len(start_address[0].split(".")) > + ldigits =3D start_address[0].count(".") >=20 > # How many octets do we need to add? > # (LACNIC does not seem to have a /8 or greater assigned, so the foll= owing should suffice.) > --=20 > 2.26.2 --===============3463480525211469568==--