do not hold a lock when calling AudioEngine::update_latencies() from Session::update_latency_compensation().

Only when using JACK1 is ::update_latencies() a synchronous call (ending up in Session::update_latency() which tries to take the
same lock). But the semantics of ::update_latencies() are sufficiently ill-defined that entering that call with a lock held
seems like a bad idea, so we release the lock unconditionally here.
This commit is contained in:
Paul Davis 2019-10-28 13:39:59 -06:00
parent 8befc818eb
commit fe56c5931c
1 changed files with 2 additions and 0 deletions

View File

@ -6514,6 +6514,8 @@ Session::update_latency_compensation (bool force_whole_graph)
if (some_track_latency_changed || force_whole_graph) {
DEBUG_TRACE (DEBUG::LatencyCompensation, "update_latency_compensation: delegate to engine\n");
/* cannot hold lock while engine initiates a full latency callback */
lx.release ();
_engine.update_latencies ();
/* above call will ask the backend up update its latencies, which
* eventually will trigger AudioEngine::latency_callback () and