This repository has been archived by the owner on Sep 6, 2019. It is now read-only.
This repository has been archived by the owner on Sep 6, 2019. It is now read-only.
IPlugVST3 might crash the Plugin when initalizing reqNumInputChannels or reqNumOutputChannels #60
Open
Description
Lines 278 and 279 at IPlugVST3 might cause an access violation if the 'inputs' or 'outputs' arrays are empty (for example in a VST instrument). I've encountered this error in Win x64 Debug configuration of my VST3 plugin.
It would be safer if the code looked if there are any channels initialized and then get their speaker arrangement. For example.
int32 reqNumInputChannels = 0;
if(NInChannels() > 0)
reqNumInputChannels = SpeakerArr::getChannelCount(inputs[0]); //requested # input channels
int32 reqNumOutputChannels = 0;
if(NOutChannels() > 0)
reqNumOutputChannels = SpeakerArr::getChannelCount(outputs[0]);//requested # output channels
- I'm sorry if I'm doing something wrong its the first time I try to contribute to Github :)
Metadata
Assignees
Labels
No labels
Activity