Browse Source

Only allow binding to IPv6 when ipv6_hosting enabled

For some reason it was always binding to IPv6, even when disabled (on Windows)
pull/711/head
Safihre 9 years ago
parent
commit
8e97097dfd
  1. 5
      SABnzbd.py

5
SABnzbd.py

@ -528,7 +528,8 @@ def all_localhosts():
ips = []
for item in info:
item = item[4][0]
if item not in ips:
# Only return IPv6 when enabled
if item not in ips and ('::1' not in item or sabnzbd.cfg.ipv6_hosting()):
ips.append(item)
return ips
@ -1393,7 +1394,7 @@ def main():
hosts[1] = '::1'
# The Windows binary requires numeric localhost as primary address
if multilocal and cherryhost == 'localhost':
if cherryhost == 'localhost':
cherryhost = hosts[0]
if enable_https:

Loading…
Cancel
Save