From 3dec6f11d625a351bae0aada4160f3d2de429cdd Mon Sep 17 00:00:00 2001 From: Claudio Takahasi Date: Fri, 18 Aug 2006 18:29:40 +0000 Subject: Fixed SetMode when the adapter is DOWN --- hcid/dbus-sdp.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'hcid/dbus-sdp.c') diff --git a/hcid/dbus-sdp.c b/hcid/dbus-sdp.c index fe3ad04a..edf220a9 100644 --- a/hcid/dbus-sdp.c +++ b/hcid/dbus-sdp.c @@ -1111,11 +1111,15 @@ static struct service_data sdp_services[] = { DBusHandlerResult handle_sdp_method(DBusConnection *conn, DBusMessage *msg, void *data) { + const struct hci_dbus_data *pdata = data; service_handler_func_t handler; if (!hcid_dbus_use_experimental()) return error_unknown_method(conn, msg); + if (!pdata->up) + return error_not_ready(conn, msg); + handler = find_service_handler(sdp_services, msg); if (handler) -- cgit