#include "autofill_manager_stub.h"
#include "autofill_config.h"
+#define RECONNECT_PERIOD 1.0
+
static rpc_port_proxy_AutofillSvcPort_h svc_rpc_h = NULL;
static rpc_port_AutofillSvcPort_autofill_svc_fill_response_cb_h fill_response_received_cb_h = NULL;
static rpc_port_AutofillSvcPort_autofill_svc_auth_info_cb_h auth_info_cb_h = NULL;
return ECORE_CALLBACK_RENEW;
}
-//LCOV_EXCL_START
-static void __on_disconnected(rpc_port_proxy_AutofillSvcPort_h h, void *user_data)
+static void retry_connect_service()
{
- LOGW("Autofill service is disconnected");
-
svc_rpc_h = NULL;
if (fill_response_received_cb_h) {
if (g_connect_timer)
ecore_timer_del(g_connect_timer);
- g_connect_timer = ecore_timer_add(1.0, connect_timer_cb, NULL);
+ g_connect_timer = ecore_timer_add(RECONNECT_PERIOD, connect_timer_cb, NULL);
}
}
+//LCOV_EXCL_START
+static void __on_disconnected(rpc_port_proxy_AutofillSvcPort_h h, void *user_data)
+{
+ LOGW("Autofill service is disconnected");
+
+ retry_connect_service();
+}
+
static void __on_rejected(rpc_port_proxy_AutofillSvcPort_h h, void *user_data)
{
LOGW("Rejected to connect autofill service");
+
+ retry_connect_service();
}
//LCOV_EXCL_STOP