Invalid / Double free issue on MacOSX.