From 191939cd806c9d5bc1f7e4b9113298c48b764cc0 Mon Sep 17 00:00:00 2001 From: falkTX Date: Sat, 16 Mar 2019 11:40:25 +0100 Subject: [PATCH] jackbridge: return success if jack_connect returns EEXIST Signed-off-by: falkTX --- source/jackbridge/JackBridge1.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/source/jackbridge/JackBridge1.cpp b/source/jackbridge/JackBridge1.cpp index 9766f7d2c..d54d2e829 100644 --- a/source/jackbridge/JackBridge1.cpp +++ b/source/jackbridge/JackBridge1.cpp @@ -29,6 +29,7 @@ # define JACKSYM_API #endif +#include #include "CarlaLibUtils.hpp" // ----------------------------------------------------------------------------- @@ -1539,7 +1540,10 @@ bool jackbridge_connect(jack_client_t* client, const char* source_port, const ch return (jack_connect(client, source_port, destination_port) == 0); #else if (getBridgeInstance().connect_ptr != nullptr) - return (getBridgeInstance().connect_ptr(client, source_port, destination_port) == 0); + { + const int ret = getBridgeInstance().connect_ptr(client, source_port, destination_port); + return ret == 0 || ret == EEXIST; + } #endif return false; }