call malloc_trim only on linux
This commit is contained in:
parent
78c561c12e
commit
b504dc04c2
@ -1,8 +1,9 @@
|
||||
from ctypes import cdll
|
||||
from ctypes.util import find_library
|
||||
from sys import platform
|
||||
|
||||
lib_name = find_library('c')
|
||||
if not lib_name:
|
||||
if not lib_name or platform != 'linux':
|
||||
libc = None
|
||||
else:
|
||||
libc = cdll.LoadLibrary(lib_name)
|
||||
|
Loading…
Reference in New Issue
Block a user