From: Matthias Kruk Date: Sat, 15 Apr 2023 07:26:37 +0000 (+0900) Subject: include/ipc: Correctly assign `topics' in ipc_endpoint_subscribe() X-Git-Url: https://git.corax.cc/?a=commitdiff_plain;h=5773685a911315001b89c7bb38c380b490bd4cd3;p=toolbox include/ipc: Correctly assign `topics' in ipc_endpoint_subscribe() The `topics' argument of ipc_endpoint_subscribe() is not assigned from an array, causing the function to subscribe only to the first topic that is passed to it. This commit fixes the assignment of the `topics' argument of ipc_endpoint_subscribe() so that the function will subscribe an endpoint to more than one topic. --- diff --git a/include/ipc.sh b/include/ipc.sh index 194f48c..b53df74 100644 --- a/include/ipc.sh +++ b/include/ipc.sh @@ -692,7 +692,7 @@ _ipc_endpoint_topic_get_subscribers_and_taps() { ipc_endpoint_subscribe() { local endpoint="$1" - local topics="$2" + local topics=("${@:2}") local topic local -a succeeded