summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/conf_mode/service_upnp.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/conf_mode/service_upnp.py b/src/conf_mode/service_upnp.py
index 8bf6f43b4..638296f45 100755
--- a/src/conf_mode/service_upnp.py
+++ b/src/conf_mode/service_upnp.py
@@ -82,7 +82,7 @@ def get_all_interface_addr(prefix, filter_dev, filter_family):
for addr in addrs[netifaces.AF_INET6]:
if prefix:
# we need to manually assemble a list of IPv4 address/prefix
- bits = bin(int(addr['netmask'].replace(':', ''), 16)).count('1')
+ bits = bin(int(addr['netmask'].replace(':', '').split('/')[0], 16)).count('1')
prefix = '/' + str(bits)
list_addr.append(addr['addr'] + prefix)
else: