1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-18 17:10:05 +02:00

Bug 2019 - Scriptables: Set Envelope allows envelope points at zero which can cause NaNs

This commit is contained in:
James Crook 2018-10-29 18:05:31 +00:00
parent 6a4663e19c
commit c79d65cdeb

View File

@ -73,7 +73,7 @@ bool SetEnvelopeCommand::ApplyInner( const CommandContext & context, Track * t )
if( bHasDelete && mbDelete ) if( bHasDelete && mbDelete )
pEnv->mEnv.clear(); pEnv->mEnv.clear();
if( bHasT && bHasV ) if( bHasT && bHasV )
pEnv->InsertOrReplace( mT, mV ); pEnv->InsertOrReplace( mT, pEnv->ClampValue( mV ) );
} }
} }
} ); } );