summaryrefslogtreecommitdiffstats
path: root/input
diff options
context:
space:
mode:
authorClaudio Takahasi <claudio.takahasi@openbossa.org>2008-05-01 13:52:26 +0000
committerClaudio Takahasi <claudio.takahasi@openbossa.org>2008-05-01 13:52:26 +0000
commit9491a544f622e40453265c30f24ce44a61440cc1 (patch)
tree2c00a3c63c9f021444a6b89f6f22369bf3a3073f /input
parent3f8860031e5241fbb145fdd71e1a46c2c28f393e (diff)
Moving authorization code to dbus-service.c
Diffstat (limited to 'input')
-rw-r--r--input/main.c5
-rw-r--r--input/server.c7
2 files changed, 5 insertions, 7 deletions
diff --git a/input/main.c b/input/main.c
index dab730b7..d8236ada 100644
--- a/input/main.c
+++ b/input/main.c
@@ -28,12 +28,11 @@
#include <errno.h>
#include <bluetooth/bluetooth.h>
-#include <glib.h>
-#include <dbus/dbus.h>
+
+#include "dbus.h"
#include "plugin.h"
#include "dbus-service.h"
-#include "dbus.h"
#include "manager.h"
#define HID_UUID "00001124-0000-1000-8000-00805f9b34fb"
diff --git a/input/server.c b/input/server.c
index 6cfd0d37..ff7cdbfd 100644
--- a/input/server.c
+++ b/input/server.c
@@ -45,8 +45,7 @@
#include "device.h"
#include "server.h"
#include "storage.h"
-
-#include "plugin.h"
+#include "dbus-service.h"
static const char* HID_UUID = "00001124-0000-1000-8000-00805f9b34fb";
@@ -111,7 +110,7 @@ static void auth_callback(DBusError *derr, void *user_data)
if (derr) {
error("Access denied: %s", derr->message);
if (dbus_error_has_name(derr, DBUS_ERROR_NO_REPLY))
- plugin_cancel_auth(&auth->dst);
+ service_cancel_auth(&auth->dst);
input_device_close_channels(&auth->src, &auth->dst);
} else
@@ -133,7 +132,7 @@ static int authorize_device(bdaddr_t *src, bdaddr_t *dst)
bacpy(&auth->src, src);
bacpy(&auth->dst, dst);
- retval = plugin_req_auth(src, dst, HID_UUID,
+ retval = service_req_auth(src, dst, HID_UUID,
auth_callback, auth);
if (retval < 0)
goto fallback;