fix a new/malloc/free/delete memory error
now it build with SDL