service: Use correct DBUS data type to pack disconnect reason 99/126599/1
authorSaurav Babu <saurav.babu@samsung.com>
Mon, 24 Apr 2017 08:37:02 +0000 (14:07 +0530)
committerSaurav Babu <saurav.babu@samsung.com>
Mon, 24 Apr 2017 08:38:09 +0000 (14:08 +0530)
disconnect_reason can have negative values, so we should use
DBUS_TYPE_INT32 instead of DBUS_TYPE_UINT32 to pack.

Change-Id: Ia4cc303741461da5b8d42493779b8623a0482a33
Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
src/service.c

index 772c89f..6e99979 100755 (executable)
@@ -3269,7 +3269,7 @@ static void append_properties(DBusMessageIter *dict, dbus_bool_t limited,
                                                append_ethernet, service);
 
                connman_dbus_dict_append_basic(dict, "DisconnectReason",
-                               DBUS_TYPE_UINT32, &service->disconnect_reason);
+                               DBUS_TYPE_INT32, &service->disconnect_reason);
 
                break;
 #endif