From 2d7b58b2d4c0888571886446facc7bb78eea5812 Mon Sep 17 00:00:00 2001 From: Hwankyu Jhun Date: Thu, 1 Jun 2017 17:32:28 +0900 Subject: [PATCH] Fix plugin parameter - Add argc and argv parameters to APPCORE_UI_PLUGIN_INIT Change-Id: I79997fdfbb5fcc6f9a5d5cb739c01f7fe56dc061 Signed-off-by: Hwankyu Jhun --- include/appcore_ui_plugin.h | 3 ++- src/ui_base/appcore_ui_base.c | 2 +- src/ui_base/appcore_ui_plugin.c | 8 +++++--- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/include/appcore_ui_plugin.h b/include/appcore_ui_plugin.h index e254286..d212762 100644 --- a/include/appcore_ui_plugin.h +++ b/include/appcore_ui_plugin.h @@ -19,7 +19,8 @@ #include "appcore_ui_base.h" -void appcore_ui_plugin_init(appcore_ui_base_ops *ops, unsigned int *hint); +void appcore_ui_plugin_init(appcore_ui_base_ops *ops, int argc, char **argv, + unsigned int *hint); void appcore_ui_plugin_fini(void); #endif /* __APPCORE_UI_PLUGIN_H__ */ diff --git a/src/ui_base/appcore_ui_base.c b/src/ui_base/appcore_ui_base.c index 2696bfe..822aabc 100644 --- a/src/ui_base/appcore_ui_base.c +++ b/src/ui_base/appcore_ui_base.c @@ -695,7 +695,7 @@ EXPORT_API int appcore_ui_base_init(appcore_ui_base_ops ops, int argc, char **ar int r; bool is_vc_vt_automode = false; - appcore_ui_plugin_init(&ops, &hint); + appcore_ui_plugin_init(&ops, argc, argv, &hint); aul_app_get_appid_bypid(getpid(), appid, sizeof(appid)); __context.ops = ops; __context.data = data; diff --git a/src/ui_base/appcore_ui_plugin.c b/src/ui_base/appcore_ui_plugin.c index f25b60e..73fea5e 100644 --- a/src/ui_base/appcore_ui_plugin.c +++ b/src/ui_base/appcore_ui_plugin.c @@ -32,7 +32,8 @@ #define APPCORE_UI_PLUGIN_INIT "APPCORE_UI_PLUGIN_INIT" #define APPCORE_UI_PLUGIN_FINI "APPCORE_UI_PLUGIN_FINI" -static int (*__plugin_init)(appcore_ui_base_ops *ops, unsigned int *hint); +static int (*__plugin_init)(appcore_ui_base_ops *ops, int argc, char **argv, + unsigned int *hint); static int (*__plugin_fini)(void); static void *__handle; @@ -69,7 +70,8 @@ static void __load_appcore_ui_plugin(void) LOGW("Failed to load %s symbol", APPCORE_UI_PLUGIN_FINI); } -void appcore_ui_plugin_init(appcore_ui_base_ops *ops, unsigned int *hint) +void appcore_ui_plugin_init(appcore_ui_base_ops *ops, int argc, char **argv, + unsigned int *hint) { LOGI("[PLUGIN] init"); @@ -77,7 +79,7 @@ void appcore_ui_plugin_init(appcore_ui_base_ops *ops, unsigned int *hint) __load_appcore_ui_plugin(); if (__plugin_init) - __plugin_init(ops, hint); + __plugin_init(ops, argc, argv, hint); } void appcore_ui_plugin_fini(void) -- 2.7.4