X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fafb-api-so.c;h=bcd8dbe03161355ca3d3a76911999334da19e7d6;hb=5c1e761a2f84439b6e53ff1682ee665a7db2bca1;hp=693385d5aac23cf7c8f9b740f5dc9bd6d51d01b3;hpb=031601a0c5aa944493660f991d66702cc7e52755;p=src%2Fapp-framework-binder.git diff --git a/src/afb-api-so.c b/src/afb-api-so.c index 693385d5..bcd8dbe0 100644 --- a/src/afb-api-so.c +++ b/src/afb-api-so.c @@ -48,7 +48,7 @@ struct api_so_desc { static int api_timeout = 15; -static const char plugin_register_function[] = "pluginAfbV1Entry"; +static const char plugin_register_function[] = "pluginAfbV1Register"; static void afb_api_so_event_sender_push(struct api_so_desc *desc, const char *name, struct json_object *object) { @@ -187,6 +187,10 @@ int afb_api_so_add_plugin(const char *path) ERROR("plugin [%s] bad prefix...", path); goto error3; } + if (!afb_apis_is_valid_api_name(desc->plugin->v1.prefix)) { + ERROR("plugin [%s] invalid prefix...", path); + goto error3; + } if (desc->plugin->v1.info == NULL || *desc->plugin->v1.info == 0) { ERROR("plugin [%s] bad description...", path); goto error3;