Heap corruption detected - iPhone 5S only

audio, core-audio, ios, objective-c

Solution

The iPhone 5s has an arm64/64-bit CPU. Check all the analyze compiler warnings for trying to store 64-bit pointers (and other values) into 32-bit C data types.

Also make sure all your audio code parameter passing, object messaging, and manual memory management code is thread safe, and meets all real-time requirements.

Problem

I am developing an app that listens for frequency/pitches, it works fine on iPhone4s, simulator and others but not iPhone 5S. This is the message I am getting: ``` malloc: *** error for object 0x178203a00: Heap corruption detected, free list canary is damaged ``` Any suggestion where should I start to dig into? Thanks!

Original source