fixed deprecation of <malloc.h> in OSX, replaced by <malloc/malloc.h>