diff options
author | INSUN PYO <insun.pyo@samsung.com> | 2017-03-23 16:49:21 +0900 |
---|---|---|
committer | INSUN PYO <insun.pyo@samsung.com> | 2017-03-26 18:42:24 -0700 |
commit | efb4336bb882bcc8a561aae3d74574fa5df19750 (patch) | |
tree | 092255cb91f610feb07accd3a507616a054b551b | |
parent | a31a805276086ead48672248cac8d2da4c373d37 (diff) | |
download | dbus-efb4336bb882bcc8a561aae3d74574fa5df19750.tar.gz dbus-efb4336bb882bcc8a561aae3d74574fa5df19750.tar.bz2 dbus-efb4336bb882bcc8a561aae3d74574fa5df19750.zip |
cynara: add exception code for disconnection code.submit/tizen_3.0/20170327.014319accepted/tizen/3.0/wearable/20170328.051925accepted/tizen/3.0/tv/20170328.051858accepted/tizen/3.0/mobile/20170328.051803accepted/tizen/3.0/ivi/20170328.052011accepted/tizen/3.0/common/20170328.141819
For disconnection connections, _dbus_connection_get_dispatch_status_unlocked always returns DBUS_DISPATCH_DATA_REMAINS.
So __bus_loop_dispatch is going around in an infinite loop.
If _dbus_loop_dispatch is out of the loop, _dbus_connection_get_dispatch_status_unlocked returns DBUS_DISPATCH_COMPLETE as normal.
It is dead-lock.
====================== reproduce ==================
su - owner
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
dbus-send --type=method_call --system --dest=org.tizen.system.deviced /Org/Tizen/System/DeviceD/Display org.tizen.system.deviced.display.CustomBrightness
===================================================
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I8565a757a62b50a27d2c6b6931e125af452ff74e
(cherry picked from commit 30f31f92bbe969e88386ac484061e715837d6aca)
-rw-r--r-- | dbus/dbus-connection.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dbus/dbus-connection.c b/dbus/dbus-connection.c index 9a5be336..4537edd2 100644 --- a/dbus/dbus-connection.c +++ b/dbus/dbus-connection.c @@ -4381,7 +4381,7 @@ static DBusDispatchStatus _dbus_connection_get_dispatch_status_unlocked (DBusConnection *connection) { HAVE_LOCK_CHECK (connection); - if (connection->dispatch_disabled && dbus_connection_get_is_connected(connection)) + if (connection->dispatch_disabled) return DBUS_DISPATCH_COMPLETE; else if (connection->n_incoming > 0) return DBUS_DISPATCH_DATA_REMAINS; |