From 7d9b9b462c8cb28b59e6e82440218928441c34b8 Mon Sep 17 00:00:00 2001 From: DoHyun Pyun Date: Tue, 4 Apr 2017 13:48:29 +0900 Subject: Fix the svace issue (11726, 176047, 183477) Change-Id: Ia399f87f8d869f18afe7fef883dfea36a891b9e8 Signed-off-by: DoHyun Pyun --- src/bluetooth-common.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/bluetooth-common.c') diff --git a/src/bluetooth-common.c b/src/bluetooth-common.c index 42c1b53..7d1b12e 100644 --- a/src/bluetooth-common.c +++ b/src/bluetooth-common.c @@ -3591,6 +3591,7 @@ int _bt_gatt_client_update_all(bt_gatt_client_h client) ret = _bt_get_error_code(ret); if (ret != BT_ERROR_NONE) { BT_ERR("bluetooth_gatt_get_primary_services is failed"); + g_free(prim_svc); return ret; } @@ -3678,6 +3679,7 @@ int _bt_gatt_client_update_all(bt_gatt_client_h client) g_strfreev(prim_svc->handle); g_free(prim_svc); + prim_svc = NULL; if (svc_list == NULL) return BT_ERROR_OPERATION_FAILED; -- cgit v1.2.3