mirror of
https://github.com/frappe/gunicorn.git
synced 2026-01-14 11:09:11 +08:00
catch ValueError when ipv6 isn't not supported on the platform
fix #479
This commit is contained in:
parent
c31e0f9ac7
commit
9acafc25f0
@ -209,6 +209,8 @@ def is_ipv6(addr):
|
||||
socket.inet_pton(socket.AF_INET6, addr)
|
||||
except socket.error: # not a valid address
|
||||
return False
|
||||
except ValueError: # ipv6 not supported on this platform
|
||||
return False
|
||||
return True
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user