diff options
author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2017-05-25 13:31:32 +0300 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2017-05-29 16:02:34 +0300 |
commit | f585e7ac8da3ba20fc465e3c255d2a88b7390977 (patch) | |
tree | 6ae72bf26f07d1d1e75e3160947f7effd68dce7f /client/gatt.h | |
parent | 6b34bdd967a639c2d219b5d83f0a20637c56e68e (diff) | |
download | bluez-f585e7ac8da3ba20fc465e3c255d2a88b7390977.tar.gz |
client: Fix using RegisterProfile
RegisterProfile no longer works for registering GattProfile instances
as this functionality has been moved to RegisterApplication.
In order to make this more clear this replaces the (un)register-profile
with (un)register-application and enable ObjectManager, here is an
example how to register for 12345678-1234-5678-1234-56789abcdef1:
[bluetooth]# register-application 12345678-1234-5678-1234-56789abcdef1
Application registered
bluetoothd[8777]: src/gatt-database.c:manager_register_app() Registering application: :1.483:/
bluetoothd[8777]: src/gatt-database.c:proxy_added_cb() Object received: /org/bluez/application, iface: org.bluez.GattProfile1
bluetoothd[8777]: src/gatt-database.c:proxy_added_cb() Object received: /org/bluez/agent, iface: org.bluez.Agent1
bluetoothd[8777]: src/gatt-database.c:profile_add() Added ":1.483/org/bluez/application/12345678-1234-5678-1234-56789abcdef1"
bluetoothd[8777]: src/gatt-database.c:client_ready_cb() GATT application registered: :1.483:/
[bluetooth]# unregister-application
Application unregistered
bluetoothd[8777]: src/gatt-database.c:profile_remove() Removed ":1.483/org/bluez/application/12345678-1234-5678-1234-56789abcdef1"
bluetoothd[8777]: src/gatt-database.c:profile_release() Releasing ":1.483"
Diffstat (limited to 'client/gatt.h')
-rw-r--r-- | client/gatt.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/client/gatt.h b/client/gatt.h index 7a91975d1..4c9fd5b7d 100644 --- a/client/gatt.h +++ b/client/gatt.h @@ -41,6 +41,5 @@ void gatt_notify_attribute(GDBusProxy *proxy, bool enable); void gatt_add_manager(GDBusProxy *proxy); void gatt_remove_manager(GDBusProxy *proxy); -void gatt_register_profile(DBusConnection *conn, GDBusProxy *proxy, - wordexp_t *w); -void gatt_unregister_profile(DBusConnection *conn, GDBusProxy *proxy); +void gatt_register_app(DBusConnection *conn, GDBusProxy *proxy, wordexp_t *w); +void gatt_unregister_app(DBusConnection *conn, GDBusProxy *proxy); |