odissey: detach client on setup connect error
@@ -249,9 +249,11 @@ od_frontend_setup_parameters(od_client_t *client)
int rc;
if (server->io == NULL) {
rc = od_backend_connect(server, "setup");
- if (rc == -1)
+ if (rc == -1) {
+ od_router_detach(client);
return -1;
}
+ }
/* discard last server configuration */
od_route_t *route = client->route;
