From 0ea75ab4bb3ff96a50785cf2b9860011c49fd7b7 Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Mon, 29 Dec 2014 11:31:43 -0200 Subject: [PATCH] attrib: Fix warning when closing connection Since bt_att is used internally GAttrib should no longer close the connection otherwise it cause the following warning: bluetoothd[31756]: attrib/gattrib.c:g_attrib_unref() 0x610c130: g_attrib_unref=1 bluetoothd[31756]: attrib/gattrib.c:g_attrib_unref() 0x610c130: g_attrib_unref=0 (bluetoothd:31756): GLib-WARNING **: Invalid file descriptor. --- attrib/gattrib.c | 1 + 1 file changed, 1 insertion(+) diff --git a/attrib/gattrib.c b/attrib/gattrib.c index 2fd06e6df..82a6133c0 100644 --- a/attrib/gattrib.c +++ b/attrib/gattrib.c @@ -108,6 +108,7 @@ GAttrib *g_attrib_new(GIOChannel *io, guint16 mtu) if (!attr) return NULL; + g_io_channel_set_close_on_unref(io, FALSE); g_io_channel_ref(io); attr->io = io; -- 2.47.3