Commit 97e9f0ff authored by Léo-Paul Géneau's avatar Léo-Paul Géneau 👾

Fix exit hanging when pubsub was not started

parent 35165835
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
static JSClassID jsDroneClassId; static JSClassID jsDroneClassId;
static UA_Boolean pubsubShouldRun = true; static UA_Boolean pubsubShouldRun = true;
static UA_Boolean pubsubExited = false; static UA_Boolean pubsubExited = true;
static UA_UInt32 nbDrone; static UA_UInt32 nbDrone;
static UA_UInt32 nbSubscriber; static UA_UInt32 nbSubscriber;
...@@ -447,6 +447,7 @@ static JSValue js_run_pubsub(JSContext *ctx, JSValueConst this_val, ...@@ -447,6 +447,7 @@ static JSValue js_run_pubsub(JSContext *ctx, JSValueConst this_val,
instanceArray[i].init_node_id = init_subscriber_node_id; instanceArray[i].init_node_id = init_subscriber_node_id;
} }
pubsubExited = false;
res = runPubsub(logger, &transportProfile, &networkAddressUrl, variables, res = runPubsub(logger, &transportProfile, &networkAddressUrl, variables,
id, instanceArray, nbPeer, MAX_VARIABLE_NB, interval, id, instanceArray, nbPeer, MAX_VARIABLE_NB, interval,
get_drone_id, pubsub_get_value, pubsub_update_variables, get_drone_id, pubsub_get_value, pubsub_update_variables,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment