PluginDirectoryScanner best methods


I’ve searched the forum and looked at the posts over the years… and there’s never been a definitive answer for the best way to scan for plugins and deal with any bad plugins. I don’t mean plugins that fail to validate and get added to the black-list… but plugins which can cause your scanner process to crash or hang.

The best thread I’ve found is this one… but even that doesn’t have any concrete answers.

I wrote a “VeryBadPlugin” VST which is a basic ProJucer created Plugin project and I make it crash right away:

#ifndef JucePlugin_PreferredChannelConfigurations
     : AudioProcessor (BusesProperties()
                     #if ! JucePlugin_IsMidiEffect
                      #if ! JucePlugin_IsSynth
                       .withInput  ("Input",  AudioChannelSet::stereo(), true)
                       .withOutput ("Output", AudioChannelSet::stereo(), true)


 void VeryBadPluginAudioProcessor::crashMe()

If I scan the VST folder with this VeryBadPlugin using Tracktion… it bypasses the plugin and adds it to the black-list and the Tracktion scanner process doesn’t crash. Obviously the Tracktion scanner detects the plugin has caused a crash and restarts the scanner from where it left off… but how does it do that?

If I try and scan this same plugin using my scanner app (which also runs in a separate process) it crashes the scanner and I get a crash report.

Stepping though the code in debug with my scanner app it gets to VSTPluginInstance::constructEffect() and shows a SIGABRT at line 1581 at:


Can you tell us how you handle this in Tracktion?

I’ve tried using SystemStats::setApplicationCrashHandler() and that didn’t get triggered.



How to catch an error in KnownPluginList::scanAndAddFile()?

Well I found how to have Xcode not break on SIGABRT and SIGKILL

So now at least I can test SystemStats::setApplicationCrashHandler() and have my scanner not generating a crash log.