mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-08 14:13:57 +01:00
Assert that sampleCount doesn't narrow converting to 3d party types
This commit is contained in:
@@ -306,11 +306,15 @@ bool EffectSBSMS::Process()
|
||||
outResampleCB = resampleCB;
|
||||
rb.offset = start;
|
||||
rb.end = end;
|
||||
// Third party library has its own type alias, check it
|
||||
static_assert(sizeof(sampleCount::type) <=
|
||||
sizeof(_sbsms_::SampleCountType),
|
||||
"Type _sbsms_::SampleCountType is too narrow to hold a sampleCount");
|
||||
rb.iface = std::make_unique<SBSMSInterfaceSliding>(&rateSlide,&pitchSlide,
|
||||
bPitchReferenceInput,
|
||||
samplesToProcess,0,
|
||||
nullptr);
|
||||
|
||||
|
||||
|
||||
} else {
|
||||
rb.bPitch = false;
|
||||
|
||||
Reference in New Issue
Block a user