power: Fixed a bug to use the wrong dbus path and interface for reboot. 53/125853/1 accepted/tizen/unified/20170419.165317 submit/tizen/20170419.062310
authorwchang kim <wchang.kim@samsung.com>
Wed, 19 Apr 2017 06:17:22 +0000 (15:17 +0900)
committerwchang kim <wchang.kim@samsung.com>
Wed, 19 Apr 2017 06:17:22 +0000 (15:17 +0900)
Change-Id: I0da5b494faec0931b3d1f21af872c5ae88fcbb99

src/dbus.h
src/power.c

index 27a58e0..11d13ce 100644 (file)
 #define DEVICED_PATH_POWER                  DEVICED_OBJECT_PATH"/Power"
 #define DEVICED_INTERFACE_POWER             DEVICED_INTERFACE_NAME".power"
 
+/* Reboot service: request reboot operation */
+#define DEVICED_PATH_REBOOT                 DEVICED_OBJECT_PATH"/Reboot"
+#define DEVICED_INTERFACE_REBOOT            DEVICED_INTERFACE_NAME".reboot"
+
 /* IR service: transmit IR commands */
 #define DEVICED_PATH_IR                  DEVICED_OBJECT_PATH"/Ir"
 #define DEVICED_INTERFACE_IR             DEVICED_INTERFACE_NAME".ir"
index fa72469..5359fa9 100644 (file)
@@ -481,8 +481,8 @@ int device_power_reboot(const char *reason)
        }
 
        ret = dbus_method_sync(DEVICED_BUS_NAME,
-                       DEVICED_PATH_POWER,
-                       DEVICED_INTERFACE_POWER,
+                       DEVICED_PATH_REBOOT,
+                       DEVICED_INTERFACE_REBOOT,
                        method, sig, arr);
        return errno_to_device_error(ret);
 }