From df0720052fac1a5b8021f053f7cc19bb66fa4129 Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Fri, 12 Jun 2020 14:44:20 +0000 Subject: [PATCH] location: Fix handling of families argument This was ignored, because it was already converted before and the export function was expecting a string. Fixes: #12436 Signed-off-by: Michael Tremer --- src/python/location.in | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/python/location.in b/src/python/location.in index 6ced5f5..d37294d 100644 --- a/src/python/location.in +++ b/src/python/location.in @@ -517,10 +517,8 @@ class CLI(object): countries, asns = [], [] # Translate family - if ns.family == "ipv6": - families = [ socket.AF_INET6 ] - elif ns.family == "ipv4": - families = [ socket.AF_INET ] + if ns.family: + families = [ ns.family ] else: families = [ socket.AF_INET6, socket.AF_INET ] -- 2.39.2