Commit: ef77cc7a527b3703783617d0afc75a5aad135771
Parent: 56419b9cc000214b5dcb6cd22b9796c9aab41dc6
Author: Anderson Lizardo <anderson.lizardo@openbossa.org>
Committer: Johan Hedberg <johan.hedberg@intel.com>
Date: 2014-03-05 22:39:01
Tree: 41c3df8fa721c8405aa1659abd2a7f2521ecb6fa

core: Fix associating a GAttrib to a device on incoming connections If BlueZ is running as slave, incoming connections using ATT CID will have a GAttrib created for them. But this GAttrib will not be assigned to the underlying device (whose struct btd_device instance was created in response to the Device Connected mgmt event). This patch fixes this by assigning the GAttrib to the btd_device as soon as a connection is first requested, which is done using attio callbacks. Note that a new GAttrib reference is taken because attio callbacks "own" device->attrib and thus need their own reference.

Diffstat

M src/attrib-server.c | 22 ++++++++++++++++++++++
M src/attrib-server.h | 1 +
M src/device.c | 5 +++++

3 files changed, 28 insertions(+), 0 deletions(-)

View Full Diff | Patch