13
0

use a RegionWriteLock while modifying Playlist region list in ::region_bounds_changed

This commit is contained in:
Paul Davis 2023-10-06 16:17:06 -06:00
parent d95179f571
commit 405574184a

View File

@ -1650,8 +1650,13 @@ Playlist::region_bounds_changed (const PropertyChange& what_changed, std::shared
return;
}
regions.erase (i);
regions.insert (upper_bound (regions.begin (), regions.end (), region, cmp), region);
{
RegionWriteLock rl (this);
regions.erase (i);
regions.insert (upper_bound (regions.begin (), regions.end (), region, cmp), region);
}
if (holding_state ()) {
pending_bounds.push_back (region);
@ -3577,4 +3582,3 @@ Playlist::time_domain_changed ()
}
#endif
}