mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-06 15:19:29 +02:00
Bug2170: Crash using Trim twice with unchanged selection...
... bug resulted from Envelope rewrites in 2.2.0 and not recent restructurings.
This commit is contained in:
parent
d6768f9112
commit
e0fc7e7980
@ -420,7 +420,12 @@ void Envelope::CollapseRegion( double t0, double t1, double sampleDur )
|
|||||||
// We will keep the last (or only) point that was at t1.
|
// We will keep the last (or only) point that was at t1.
|
||||||
--end;
|
--end;
|
||||||
|
|
||||||
mEnv.erase( mEnv.begin() + begin, mEnv.begin() + end );
|
if ( end < begin ) {
|
||||||
|
if ( leftPoint )
|
||||||
|
rightPoint = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
mEnv.erase( mEnv.begin() + begin, mEnv.begin() + end );
|
||||||
|
|
||||||
// Shift points left after deleted region.
|
// Shift points left after deleted region.
|
||||||
auto len = mEnv.size();
|
auto len = mEnv.size();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user