CaptureProcessor should not be reused
This lead to potentially silent stem-exports. It should not be possible to hold a shared-ptr reference of a processor that is not part of the processor chain.
This commit is contained in:
parent
a3a30e39df
commit
2c4d1e011c
@ -4333,20 +4333,18 @@ Route::listen_position_changed ()
|
||||
std::shared_ptr<CapturingProcessor>
|
||||
Route::add_export_point()
|
||||
{
|
||||
Glib::Threads::RWLock::ReaderLock lm (_processor_lock);
|
||||
if (!_capturing_processor) {
|
||||
lm.release();
|
||||
Glib::Threads::Mutex::Lock lx (AudioEngine::instance()->process_lock ());
|
||||
Glib::Threads::RWLock::WriterLock lw (_processor_lock);
|
||||
assert (!_capturing_processor);
|
||||
|
||||
/* Align all tracks for stem-export w/o processing.
|
||||
* Compensate for all plugins between the this route's disk-reader
|
||||
* and the common final downstream output (ie alignment point for playback).
|
||||
*/
|
||||
_capturing_processor.reset (new CapturingProcessor (_session, playback_latency (true)));
|
||||
configure_processors_unlocked (0, &lw);
|
||||
_capturing_processor->activate ();
|
||||
}
|
||||
Glib::Threads::Mutex::Lock lx (AudioEngine::instance()->process_lock ());
|
||||
Glib::Threads::RWLock::WriterLock lw (_processor_lock);
|
||||
|
||||
/* Align all tracks for stem-export w/o processing.
|
||||
* Compensate for all plugins between the this route's disk-reader
|
||||
* and the common final downstream output (ie alignment point for playback).
|
||||
*/
|
||||
_capturing_processor.reset (new CapturingProcessor (_session, playback_latency (true)));
|
||||
configure_processors_unlocked (0, &lw);
|
||||
_capturing_processor->activate ();
|
||||
|
||||
return _capturing_processor;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user