Fix playlist edit after edit race
After an edit option the playlist is thawed and triggers
the butler thread (SessionEvent::Overwrite) to re-read the
playlist.
If another edit operation is started the butler may reads a
region using the region's new position, but the playlist's
old range.
See also 4db1c02bd1
This commit is contained in:
parent
bdaca1d783
commit
dcc0f1cb17
@ -449,6 +449,10 @@ Playlist::end_undo ()
|
|||||||
void
|
void
|
||||||
Playlist::freeze ()
|
Playlist::freeze ()
|
||||||
{
|
{
|
||||||
|
/* flush any ongoing reads, paricularly AudioPlaylist::read(),
|
||||||
|
* before beginning to modify the playlist.
|
||||||
|
*/
|
||||||
|
RegionWriteLock rlock (this);
|
||||||
delay_notifications ();
|
delay_notifications ();
|
||||||
g_atomic_int_inc (&ignore_state_changes);
|
g_atomic_int_inc (&ignore_state_changes);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user