<label>autofilld</label>
<author email="jihoon48.kim@samsung.com" href="www.samsung.com">Jihoon Kim</author>
<description>autofilld</description>
- <service-application appid="org.tizen.autofilld" auto-restart="true" exec="autofilld" multiple="false" nodisplay="true" on-boot="true" taskmanage="false" type="capp">
+ <service-application appid="org.tizen.autofilld" exec="autofilld" multiple="false" nodisplay="true" taskmanage="false" type="capp">
<label>autofill daemon</label>
<metadata key="http://tizen.org/rpc-port/privilege-check-bypass" value="AutofillAppPort|AutofillManagerPort"/>
<background-category value="system"/>
static bool g_connected = false;
static bool connect_service();
+static void terminate_autofill_service();
static autofill_client_s *
get_autofill_client(const char *app_id, int context_id)
__client_list = g_list_remove(__client_list, client);
__destroy_client(client);
+
+ if (g_list_length(__client_list) == 0) {
+ terminate_autofill_service();
+
+ LOGI("terminate autofill daemon");
+ service_app_exit();
+ }
}
static void __message_create(rpc_port_stub_AutofillAppPort_context_h context,
}
//LCOV_EXCL_STOP
-static bool __manager_set_autofill_service_cb(rpc_port_stub_AutofillManagerPort_context_h context, const char *app_id, void *user_data)
+static void terminate_autofill_service()
{
- LOGD("autofill service app id: '%s'", app_id);
-
- if (app_id)
- autofill_config_set_autofill_service_app_id(app_id);
-
if (svc_rpc_h) {
- LOGD("send terminate");
+ LOGI("Send terminate message to autofill service");
// terminate service
rpc_port_proxy_AutofillSvcPort_invoke_request_terminate(svc_rpc_h);
}
svc_rpc_h = NULL;
+}
+
+static bool __manager_set_autofill_service_cb(rpc_port_stub_AutofillManagerPort_context_h context, const char *app_id, void *user_data)
+{
+ LOGD("autofill service app id: '%s'", app_id);
+
+ if (app_id)
+ autofill_config_set_autofill_service_app_id(app_id);
+
+ terminate_autofill_service();
connect_service();