From 7052f57ee96b95f47b66d3e7d2f24353b6ef609d Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 3 Jul 2024 18:48:39 -0600 Subject: [PATCH 1/2] no drag-n-drop for VCA masters, since they are intended to be non-reorderable --- gtk2_ardour/editor.cc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index 32811a5de8..2b6b8a573a 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -7032,7 +7032,15 @@ Editor::default_time_domain () const void Editor::start_track_drag (TimeAxisView& tav, int y, Gtk::Widget& w, bool can_change_cursor) { - track_drag = new TrackDrag (dynamic_cast (&tav), *_session); + RouteTimeAxisView* rtav = dynamic_cast (&tav); + + /* We do not allow dragging VCA Masters */ + + if (!rtav) { + return; + } + + track_drag = new TrackDrag (rtav, *_session); DEBUG_TRACE (DEBUG::TrackDrag, string_compose ("start track drag with %1\n", track_drag)); int xo, yo; From 249442fe9923f2257f43f188000759dca632462d Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 8 Jul 2024 22:40:21 -0600 Subject: [PATCH 2/2] JACK backend: fix race condition caused by not wrapping jack_set_property() in JACK_SERVER_CALL --- libs/backends/jack/jack_portengine.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/backends/jack/jack_portengine.cc b/libs/backends/jack/jack_portengine.cc index 216c9f6850..f869e3701d 100644 --- a/libs/backends/jack/jack_portengine.cc +++ b/libs/backends/jack/jack_portengine.cc @@ -178,10 +178,10 @@ int JACKAudioBackend::set_port_property (PortHandle port, const std::string& key, const std::string& value, const std::string& type) { #ifdef HAVE_JACK_METADATA // really everyone ought to have this by now. - int rv = -1; + int rv; jack_client_t* client = _jack_connection->jack(); jack_uuid_t uuid = jack_port_uuid (std::dynamic_pointer_cast(port)->jack_ptr); - return jack_set_property(client, uuid, key.c_str(), value.c_str(), type.c_str()); + JACK_SERVER_CALL (rv = jack_set_property(client, uuid, key.c_str(), value.c_str(), type.c_str())); return rv; #else return -1;