From 7233b4957186230114f7be59886a18606d74ff2d Mon Sep 17 00:00:00 2001 From: wchang kim Date: Wed, 19 Apr 2017 15:17:22 +0900 Subject: [PATCH] power: Fixed a bug to use the wrong dbus path and interface for reboot. Change-Id: I0da5b494faec0931b3d1f21af872c5ae88fcbb99 --- src/dbus.h | 4 ++++ src/power.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/dbus.h b/src/dbus.h index 27a58e0..11d13ce 100644 --- a/src/dbus.h +++ b/src/dbus.h @@ -50,6 +50,10 @@ #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" diff --git a/src/power.c b/src/power.c index fa72469..5359fa9 100644 --- a/src/power.c +++ b/src/power.c @@ -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); } -- 2.7.4