mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 14:54:56 +01:00
improved port cleanup as backend is destroyed
This commit is contained in:
parent
ec9784764c
commit
78a66b7180
5 changed files with 10 additions and 0 deletions
|
|
@ -89,6 +89,8 @@ AlsaAudioBackend::AlsaAudioBackend (AudioEngine& e, AudioBackendInfo& info)
|
||||||
|
|
||||||
AlsaAudioBackend::~AlsaAudioBackend ()
|
AlsaAudioBackend::~AlsaAudioBackend ()
|
||||||
{
|
{
|
||||||
|
clear_ports ();
|
||||||
|
|
||||||
pthread_mutex_destroy (&_port_callback_mutex);
|
pthread_mutex_destroy (&_port_callback_mutex);
|
||||||
pthread_mutex_destroy (&_device_port_mutex);
|
pthread_mutex_destroy (&_device_port_mutex);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -129,6 +129,9 @@ CoreAudioBackend::~CoreAudioBackend ()
|
||||||
{
|
{
|
||||||
delete _pcmio; _pcmio = 0;
|
delete _pcmio; _pcmio = 0;
|
||||||
delete _midiio; _midiio = 0;
|
delete _midiio; _midiio = 0;
|
||||||
|
|
||||||
|
clear_ports ();
|
||||||
|
|
||||||
pthread_mutex_destroy (&_port_callback_mutex);
|
pthread_mutex_destroy (&_port_callback_mutex);
|
||||||
pthread_mutex_destroy (&_port_registration_mutex);
|
pthread_mutex_destroy (&_port_registration_mutex);
|
||||||
pthread_mutex_destroy (&_process_callback_mutex);
|
pthread_mutex_destroy (&_process_callback_mutex);
|
||||||
|
|
|
||||||
|
|
@ -72,6 +72,7 @@ JACKAudioBackend::JACKAudioBackend (AudioEngine& e, AudioBackendInfo& info, boos
|
||||||
|
|
||||||
JACKAudioBackend::~JACKAudioBackend()
|
JACKAudioBackend::~JACKAudioBackend()
|
||||||
{
|
{
|
||||||
|
_jack_ports.clear ();
|
||||||
}
|
}
|
||||||
|
|
||||||
string
|
string
|
||||||
|
|
|
||||||
|
|
@ -106,6 +106,8 @@ PortAudioBackend::~PortAudioBackend ()
|
||||||
delete _pcmio; _pcmio = 0;
|
delete _pcmio; _pcmio = 0;
|
||||||
delete _midiio; _midiio = 0;
|
delete _midiio; _midiio = 0;
|
||||||
|
|
||||||
|
clear_ports ();
|
||||||
|
|
||||||
pthread_mutex_destroy (&_port_callback_mutex);
|
pthread_mutex_destroy (&_port_callback_mutex);
|
||||||
pthread_mutex_destroy (&_freewheel_mutex);
|
pthread_mutex_destroy (&_freewheel_mutex);
|
||||||
pthread_cond_destroy (&_freewheel_signal);
|
pthread_cond_destroy (&_freewheel_signal);
|
||||||
|
|
|
||||||
|
|
@ -69,6 +69,8 @@ PulseAudioBackend::PulseAudioBackend (AudioEngine& e, AudioBackendInfo& info)
|
||||||
|
|
||||||
PulseAudioBackend::~PulseAudioBackend ()
|
PulseAudioBackend::~PulseAudioBackend ()
|
||||||
{
|
{
|
||||||
|
clear_ports ();
|
||||||
|
|
||||||
pthread_mutex_destroy (&_port_callback_mutex);
|
pthread_mutex_destroy (&_port_callback_mutex);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue