From: José Bollo Date: Fri, 22 Sep 2017 14:09:10 +0000 (+0200) Subject: Provide the name of the API X-Git-Tag: eel_4.99.2~25 X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?p=src%2Fapp-framework-binder.git;a=commitdiff_plain;h=4a6490b96d8ac2da6a19b4f251c005ff1b1e7d61 Provide the name of the API Change-Id: I5b4e4b40385830d1b8921d079f5e7e732ec4247f Signed-off-by: José Bollo --- diff --git a/include/afb/afb-dynapi-itf.h b/include/afb/afb-dynapi-itf.h index 38978a29..682558e0 100644 --- a/include/afb/afb-dynapi-itf.h +++ b/include/afb/afb-dynapi-itf.h @@ -43,6 +43,9 @@ struct afb_dynapi /* current verbosity level */ int verbosity; + + /* the name of the api */ + const char *apiname; }; /* diff --git a/src/afb-export.c b/src/afb-export.c index f8e4be71..ce48dbe0 100644 --- a/src/afb-export.c +++ b/src/afb-export.c @@ -1080,6 +1080,7 @@ static struct afb_export *create(struct afb_apiset *apiset, const char *apiname, else { memset(export, 0, sizeof *export); export->apiname = strdup(apiname); + export->dynapi.apiname = export->apiname; export->version = version; export->state = Api_State_Pre_Init; export->session = afb_session_addref(common_session); @@ -1144,6 +1145,7 @@ void afb_export_rename(struct afb_export *export, const char *apiname) { free(export->apiname); export->apiname = strdup(apiname); + export->dynapi.apiname = export->apiname; afb_export_update_hook(export); }