mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-02-17 14:10:41 +01:00
Use socket.inet_aton for isIPV4 since Windows doesn't (always?) have inet_pton
Closes: Sf#3430008 Signed-off-by: James McCoy <jamessan@users.sourceforge.net> (cherry picked from commit 360a2036ac26d78c3f98db37239da9987f5c326a) Signed-off-by: Daniel Folkinshteyn <nanotube@users.sourceforge.net>
This commit is contained in:
parent
d8ead9bc29
commit
63ec70bc08
@ -73,7 +73,7 @@ def isIPV4(s):
|
||||
0
|
||||
"""
|
||||
try:
|
||||
return bool(socket.inet_pton(socket.AF_INET, s))
|
||||
return bool(socket.inet_aton(s))
|
||||
except socket.error:
|
||||
return False
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user