explicitly state the addess family type when checking them
This commit is contained in:
parent
88f1c4cba4
commit
a4ca2865c4
1 changed files with 2 additions and 2 deletions
|
@ -244,14 +244,14 @@ class CommunicationManager:
|
||||||
interface_family, _, _, _, interface_address = interface
|
interface_family, _, _, _, interface_address = interface
|
||||||
|
|
||||||
match interface_family:
|
match interface_family:
|
||||||
case socket.AF_INET:
|
case socket.AddressFamily.AF_INET:
|
||||||
interface_host, interface_port = interface_address
|
interface_host, interface_port = interface_address
|
||||||
|
|
||||||
# check if it matches the address interface
|
# check if it matches the address interface
|
||||||
if host == interface_host:
|
if host == interface_host:
|
||||||
return True
|
return True
|
||||||
|
|
||||||
case socket.AF_INET6:
|
case socket.AddressFamily.AF_INET6:
|
||||||
interface_host, interface_port, interface_flowinfo, interface_scope = interface_address
|
interface_host, interface_port, interface_flowinfo, interface_scope = interface_address
|
||||||
|
|
||||||
# check if it matches the address interface
|
# check if it matches the address interface
|
||||||
|
|
Loading…
Reference in a new issue