[PATCH v2 BlueZ 6/8] attrib: Fix missing D-Bus message unref on DiscoverCharacteristics

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Claudio Takahasi <claudio.takahasi@xxxxxxxxxxxxx>

This patch fixes a missing message unref when DiscoverCharacteristics on
Generic Attribute finishes.
---
 attrib/client.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/attrib/client.c b/attrib/client.c
index 57cd028..609f8b9 100644
--- a/attrib/client.c
+++ b/attrib/client.c
@@ -930,6 +930,9 @@ static void char_discovered_cb(GSList *characteristics, guint8 status,
 	reply = create_discover_char_reply(gatt->query->msg, gatt->chars);
 
 fail:
+	dbus_message_unref(gatt->query->msg);
+	gatt->query->msg = NULL;
+
 	g_dbus_send_message(gatt->conn, reply);
 	query_list_remove(gatt, current);
 	g_free(current);
-- 
1.7.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux