Add to set false as exit when dbus disconnects 72/156772/1
authorWonnam Jang <wn.jang@samsung.com>
Fri, 20 Oct 2017 01:51:23 +0000 (10:51 +0900)
committerWonnam Jang <wn.jang@samsung.com>
Fri, 20 Oct 2017 01:52:00 +0000 (01:52 +0000)
Change-Id: I7966ef43d27f65111798a8f86797d32765678695
Signed-off-by: Wonnam Jang <wn.jang@samsung.com>
client/vc_dbus.c
client/vc_mgr_dbus.c
client/vc_widget_dbus.c
server/vcd_dbus.c

index 7e690698b41d6db24de7764f893ac911a4633b7a..49d4510d6c1dbf688e609aab0808728a59186f50 100644 (file)
@@ -225,6 +225,8 @@ int vc_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_conn_sender, false);
+
        g_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
 
        if (dbus_error_is_set(&err)) {
@@ -238,6 +240,8 @@ int vc_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_conn_listener, false);
+
        int pid = getpid();
 
        char service_name[64];
@@ -1568,4 +1572,4 @@ int vc_dbus_request_auth_cancel(int pid, int mgr_pid)
        }
 
        return result;
-}
\ No newline at end of file
+}
index a552504235dbfe4dc01f13d475937423fc914924..2cfd533882687d3821c8049cb942556bae94f418 100644 (file)
@@ -628,6 +628,8 @@ int vc_mgr_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_m_conn_sender, false);
+
        /* connect to the DBUS system bus, and check for errors */
        g_m_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
 
@@ -642,6 +644,8 @@ int vc_mgr_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_m_conn_listener, false);
+
        SLOG(LOG_DEBUG, TAG_VCM, "service name is %s", VC_MANAGER_SERVICE_NAME);
 
        /* register our name on the bus, and check for errors */
index adebea10af4d4e405b1a3434fe45784dfd9e32f2..a40fd9389ef78dd20c18c7ad0ed6b14f226707cf 100644 (file)
@@ -300,6 +300,8 @@ int vc_widget_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_w_conn_sender, false);
+
        g_w_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
 
        if (dbus_error_is_set(&err)) {
@@ -313,6 +315,8 @@ int vc_widget_dbus_open_connection()
                return VC_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_w_conn_listener, false);
+
        int pid = getpid();
 
        char service_name[64];
index 0f05eede381f2ddeedce1d1aa561836cf6d9c21f..f2486e429b7552256714cb7a829c0e4aa42a4824 100755 (executable)
@@ -1089,6 +1089,8 @@ int vcd_dbus_open_connection()
                return VCD_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_conn_sender, false);
+
        /* connect to the bus and check for errors */
        g_conn_listener = dbus_bus_get_private(DBUS_BUS_SESSION, &err);
 
@@ -1102,6 +1104,8 @@ int vcd_dbus_open_connection()
                return VCD_ERROR_OPERATION_FAILED;
        }
 
+       dbus_connection_set_exit_on_disconnect(g_conn_listener, false);
+
        /* request our name on the bus and check for errors */
        ret = dbus_bus_request_name(g_conn_listener, VC_SERVER_SERVICE_NAME, DBUS_NAME_FLAG_REPLACE_EXISTING, &err);