OSDN Git Service

device: Fix NULL pointer dereference during GATT service discovery
authorAnderson Lizardo <anderson.lizardo@openbossa.org>
Tue, 14 Feb 2012 16:06:01 +0000 (12:06 -0400)
committerJohan Hedberg <johan.hedberg@intel.com>
Thu, 16 Feb 2012 13:08:30 +0000 (15:08 +0200)
commitd2c09255ef856cd68545ee0cab766a837b47e132
tree8e4e0ccd1cb5cf3445a425e142bc8da1b9b7ec8b
parent793b009033816ec13c571409e6c8d30d8f577979
device: Fix NULL pointer dereference during GATT service discovery

If reverse service discovery for GATT is triggered,
device_browse_primary() is called with a NULL "conn" parameter. This fix
is based on similar code found in device_browse_sdp().

This fixes errors like:

process 871: arguments to dbus_connection_ref() were incorrect,
assertion "connection != NULL" failed in file dbus-connection.c line
2549.
This is normally a bug in some application using the D-Bus library.
process 871: arguments to dbus_connection_get_object_path_data() were
incorrect, assertion "connection != NULL" failed in file
dbus-connection.c line 5639.
This is normally a bug in some application using the D-Bus library.
process 871: arguments to dbus_connection_register_object_path() were
incorrect, assertion "connection != NULL" failed in file
dbus-connection.c line 5461.
This is normally a bug in some application using the D-Bus library.
src/device.c