Fix memory leak in AudioToCVPitch
Signed-off-by: falkTX <falktx@falktx.com>
This commit is contained in:
parent
98fdb7f7a0
commit
38fca07f14
1 changed files with 8 additions and 0 deletions
|
@ -95,6 +95,14 @@ struct AudioToCVPitch : Module {
|
|||
configParam(PARAM_TOLERANCE, 0.f, 99.f, kDefaultTolerance, "Tolerance", " %");
|
||||
}
|
||||
|
||||
~AudioToCVPitch() override
|
||||
{
|
||||
if (pitchDetector != nullptr)
|
||||
del_aubio_pitch(pitchDetector);
|
||||
del_fvec(detectedPitch);
|
||||
del_fvec(inputBuffer);
|
||||
}
|
||||
|
||||
void process(const ProcessArgs& args) override
|
||||
{
|
||||
float cvPitch = lastUsedOutputPitch;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue