Someone posted about this on StackOverflow a few months back, but it probably belongs here.
I was getting odd error messages and crashing in my project in two places that used AKOperationEffect. Basically, I noticed that when I included an AKOperationEffect in the signal chain, the first call I made to AudioKit.start() would be okay, but any subsequent call produced an error message such as:
Could not find function called '\255\276\274\301莺@~'.
\255\276\274\301莺@~ returned an error.
And a subsequent call to AudioKit.stop() crashed the app:
AKOperationEffectIssue(9735,0x1156d1340) malloc: *** error for object 0x60400015c300: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Poking around in the View Memory Hierarchy debugger, I can see that the AKOperationEffectAudioUnit lingers around even after the AKOperationEffect reference is removed.
Here is a sample project demonstrating the problem:
https://github.com/crashingbooth/AKOperationEffectIssue
You're pretty active on AudioKit, would you like to be part of the Slack group?
I think I already am - I just haven't checked in since first joining a year or so ago.
Just want to add that as I'm closing issues I can't act, I'm pushing this up the priority as I think I can fix it.
This change fixes the project you sent over and I think its a fine change over all. There may be even more we can do to make operations more robust, but I'll call this a win for now.
Most helpful comment
This change fixes the project you sent over and I think its a fine change over all. There may be even more we can do to make operations more robust, but I'll call this a win for now.