Update for Python3

This commit is contained in:
2020-11-10 01:47:47 +00:00
parent fbfb32f8b1
commit 85aaf1385e
7 changed files with 936 additions and 722 deletions

View File

@@ -51,6 +51,7 @@ IOCTL_SIOCGIFCONF = 0x8912
def enumIpUnix():
import fcntl
# struct_size 40 if system is 64 bit
struct_size = 40 if (sys.maxsize > 2**32) else 32
inbytes = 128 * struct_size # Maximum 128 interfaces
@@ -68,3 +69,4 @@ def enumIpUnix():
struct_size)]
return [ip for ip in iplist if ip != '127.0.0.1']