mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 00:34:59 +01:00
Fix crash when cleaning up w/o destroying session
- Control-protocols may transmit data during cleanup (e.g. reset surface), and need the Audio-engine to do so. - destroying the ControlProtocolManager w/o the Session calling ::drop_protocols(), lead to a double free.
This commit is contained in:
parent
81f12f602b
commit
d0c934a9de
2 changed files with 2 additions and 1 deletions
|
|
@ -76,6 +76,7 @@ ControlProtocolManager::~ControlProtocolManager()
|
|||
|
||||
|
||||
for (list<ControlProtocolInfo*>::iterator p = control_protocol_info.begin(); p != control_protocol_info.end(); ++p) {
|
||||
(*p)->protocol = 0; // protocol was already destroyed above.
|
||||
delete (*p);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -597,13 +597,13 @@ ARDOUR::cleanup ()
|
|||
return;
|
||||
}
|
||||
|
||||
delete &ControlProtocolManager::instance();
|
||||
ARDOUR::AudioEngine::destroy ();
|
||||
|
||||
delete Library;
|
||||
#ifdef HAVE_LRDF
|
||||
lrdf_cleanup ();
|
||||
#endif
|
||||
delete &ControlProtocolManager::instance();
|
||||
#ifdef WINDOWS_VST_SUPPORT
|
||||
fst_exit ();
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue