X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fafs-main.c;h=93e49323ebdbdd0b3bf01a06c7cc0193aa538a08;hb=c8558c8a28966110aa3a356f95d3c60afe32b64a;hp=980a1bce7b4dd49634acd7427a06974ea0e3ea15;hpb=24d000c2290126abf88204089d132229d63f9a05;p=src%2Fapp-framework-binder.git diff --git a/src/afs-main.c b/src/afs-main.c index 980a1bce..93e49323 100644 --- a/src/afs-main.c +++ b/src/afs-main.c @@ -30,6 +30,7 @@ #include "afb-hswitch.h" #include "afb-hreq.h" #include "afb-apiset.h" +#include "afb-api-ws.h" #include "afb-session.h" #include "afs-supervisor.h" @@ -149,6 +150,15 @@ static void start(int signum, void *arg) goto error; } + /* export the service if required */ + if (main_config->ws_server) { + rc = afb_api_ws_add_server(main_config->ws_server, main_apiset); + if (rc < 0) { + ERROR("Can't export (ws-server) api %s: %m", main_config->ws_server); + goto error; + } + } + /* start the services */ if (afb_apiset_start_all_services(main_apiset, 1) < 0) goto error;