Ignore exception on free in cpuid.py

This commit is contained in:
Florian Bach 2021-12-09 16:53:13 +01:00
parent e1c8af47eb
commit cd47dfa229

View File

@ -137,9 +137,12 @@ class CPUID(object):
elif self.libc:
# Seems to throw exception when the program ends and
# libc is cleaned up before the object?
try:
self.libc.free.restype = None
self.libc.free.argtypes = [c_void_p]
self.libc.free(self.addr)
except:
pass
if __name__ == "__main__":
def valid_inputs():