summaryrefslogtreecommitdiff
path: root/libs/backends
diff options
context:
space:
mode:
Diffstat (limited to 'libs/backends')
-rw-r--r--libs/backends/alsa/alsa_audiobackend.cc13
1 files changed, 11 insertions, 2 deletions
diff --git a/libs/backends/alsa/alsa_audiobackend.cc b/libs/backends/alsa/alsa_audiobackend.cc
index d8ceb7f796..5d07bc1419 100644
--- a/libs/backends/alsa/alsa_audiobackend.cc
+++ b/libs/backends/alsa/alsa_audiobackend.cc
@@ -2210,9 +2210,13 @@ AlsaAudioPort::AlsaAudioPort (AlsaAudioBackend &b, const std::string& name, Port
{
memset (_buffer, 0, sizeof (_buffer));
mlock (_buffer, sizeof (_buffer));
+ _backend.port_connect_add_remove_callback (); // XXX -> RT
}
-AlsaAudioPort::~AlsaAudioPort () { }
+AlsaAudioPort::~AlsaAudioPort ()
+{
+ _backend.port_connect_add_remove_callback (); // XXX -> RT
+}
void*
AlsaAudioPort::get_buffer (pframes_t n_samples)
@@ -2253,9 +2257,14 @@ AlsaMidiPort::AlsaMidiPort (AlsaAudioBackend &b, const std::string& name, PortFl
_buffer[0].reserve(256);
_buffer[1].reserve(256);
_buffer[2].reserve(256);
+
+ _backend.port_connect_add_remove_callback (); // XXX -> RT
}
-AlsaMidiPort::~AlsaMidiPort () { }
+AlsaMidiPort::~AlsaMidiPort ()
+{
+ _backend.port_connect_add_remove_callback (); // XXX -> RT
+}
struct MidiEventSorter {
bool operator() (AlsaMidiEvent const& a, AlsaMidiEvent const& b) {