fix build with xcode
we don't have an autoreleasepool, fix mem leak