From b358f4f350211dfd9d52a0b4fbc611b0c711bcdd Mon Sep 17 00:00:00 2001 From: Claudio Takahasi Date: Wed, 23 Mar 2011 09:20:52 -0300 Subject: [PATCH] Fix memory leak of matched device drivers list --- src/device.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/device.c b/src/device.c index b4d13f27e..771a908ee 100644 --- a/src/device.c +++ b/src/device.c @@ -1111,8 +1111,7 @@ static GSList *device_match_driver(struct btd_device *device, /* match pattern driver */ match = device_match_pattern(device, *uuid, profiles); - for (; match; match = match->next) - uuids = g_slist_append(uuids, match->data); + uuids = g_slist_concat(uuids, match); } return uuids; -- 2.47.3