summaryrefslogtreecommitdiff
path: root/gtk2_ardour/audio_streamview.cc
diff options
context:
space:
mode:
authorJohannes Mueller <github@johannes-mueller.org>2020-05-10 13:13:18 +0200
committerJohannes Mueller <github@johannes-mueller.org>2020-05-10 14:53:38 +0200
commitbff9c9a5a17671de5b7c230f01ba806af4d9e0a1 (patch)
tree6cd8f3f0ed6cc1a44abfee02c377dd71ff1fedd6 /gtk2_ardour/audio_streamview.cc
parent52ae134efb055cfad701b7039df1c7544e47d011 (diff)
Work around a race condition
This covers a race condition in session transport that when synced to an external engine it sometimes occurs that at the end of ::realtime_stop() ::transport_stopped_or_stopping() returns false when ::setup_rec_box() is called. In this case the rec boxes are not erased when the recoding transport is stopped. This fixes this behavior about the remaining rec boxes, however the race condition remains. The race condition is reported in #8104. It should be considered reverting this commit once the race condition is fixed.
Diffstat (limited to 'gtk2_ardour/audio_streamview.cc')
-rw-r--r--gtk2_ardour/audio_streamview.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk2_ardour/audio_streamview.cc b/gtk2_ardour/audio_streamview.cc
index 25cd3c941a..b6de000d7e 100644
--- a/gtk2_ardour/audio_streamview.cc
+++ b/gtk2_ardour/audio_streamview.cc
@@ -196,7 +196,8 @@ AudioStreamView::setup_rec_box ()
{
//cerr << _trackview.name() << " streamview SRB region_views.size() = " << region_views.size() << endl;
- if (!_trackview.session()->transport_stopped_or_stopping()) {
+ if (!_trackview.session()->transport_stopped_or_stopping() &&
+ (_trackview.session()->transport_rolling() || _trackview.session()->get_record_enabled())) {
// cerr << "\trolling\n";