Diff between f5fd7efee7c31cd9cad98ea273716980d2591ca0 and 941dbc5f3b56fea087a3b88bc73cf2776c02d4d5

Changed Files

File Additions Deletions Status
src/device.c +3 -1 modified

Full Patch

diff --git a/src/device.c b/src/device.c
index 902c4aa..e4d5d79 100644
--- a/src/device.c
+++ b/src/device.c
@@ -4224,10 +4224,12 @@ static void load_info(struct btd_device *device, const char *local,
 		/* Load last used bearer */
 		str = g_key_file_get_string(key_file, "General",
 						"LastUsedBearer", NULL);
-		if (str)
+		if (str) {
 			device_update_last_used(device, !strcmp(str, "le") ?
 						device->bdaddr_type :
 						BDADDR_BREDR);
+			g_free(str);
+		}
 	}
 
 next: