AU Garage Band Crash

I’m getting a crash when I load my plugin into a Garage Band track. auval test successfully pass and it’s working good in Logic Pro X. The report says only one thing:

Thread 0 Crashed:: Dispatch queue:
0 0x00000001111ba584 0x1111a6000 + 83332
1 0x00000001111ba7db 0x1111a6000 + 83931
2 0x00000001111ba7db 0x1111a6000 + 83931
3 0x00000001111ba7db 0x1111a6000 + 83931

Any idea?

Yeah it’s terrible trying to debug AUv3s :frowning:. If it crashes in some completely other place in the code then it’s usually some memory corruption. Sometimes turning on the address sanitizer may help:

Can you re-produce this crash with the AUv3Synth plugin? If not, can you slowly copy&paste your code into the AUv3 demo and see when it crashes to narrow down the bug.

But it’s not an AUv3 plugin. It’s AU only?

Oh Sorry, I misread your post. Then it seems even more likely that you have some memory corruption bug. Unfortunately, enabling the address sanitizer will only work if the host was also compiled with the address sanitizer enabled. So you can’t use the address sanitizer and then test your plug-in in GarageBand.

However, it’s worth a try building your AU with the address sanitizer enabled and then also building JUCE’s plugin host with address sanitizer enabled. Then host your plug-in with the JUCE audio plug-in host.

Even if the crash normally does not happen in the JUCE audio plugin host, many memory corruption bugs will not always trigger a crash in all circumstances (for example, your plug-in works in Logic Pro). Nevertheless, the address sanitizer will still pick up any use-after free or out-of-bounds memory bugs.

Hmm, I see that this one is worse than AUV3. Thanks for your quick reply, I’ll try JUCE plugin host and address sanitizer.

The fact that it is only misbehaving in Garageband makes me wonder whether this problem may be a side effect of the fact that Garageband is the only one where AU plugins get sandboxed.

Maybe your code is not playing nicely with that?

You can check this other topic to have a little more insight about it:

1 Like

Ah yes, I forgot about that. Good point!

1 Like