summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTaejin Woo <tt.woo@samsung.com>2015-12-29 17:40:25 +0900
committerTaejin Woo <tt.woo@samsung.com>2015-12-29 17:41:14 +0900
commitb9a980505e5c557dedf06d1352b19d3d7b40060f (patch)
tree10125daac831dc64f5f796c79587c68de0acbbb9
parent7b36605fa6a7b2cf141f8c45c503e644d4f38623 (diff)
downloadbluez-b9a980505e5c557dedf06d1352b19d3d7b40060f.tar.gz
bluez-b9a980505e5c557dedf06d1352b19d3d7b40060f.tar.bz2
bluez-b9a980505e5c557dedf06d1352b19d3d7b40060f.zip
WGID : 28, 6097 Change-Id: Ifb4ce690655230a922a11d2b99f3b7d901e91b5f Signed-off-by: Taejin Woo <tt.woo@samsung.com>
-rw-r--r--src/gatt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gatt.c b/src/gatt.c
index ff31efe5..8ada2e14 100644
--- a/src/gatt.c
+++ b/src/gatt.c
@@ -764,7 +764,7 @@ gboolean gatt_unregister_internet_protocol_service(struct btd_adapter *adapter)
bt_uuid16_create(&uuid, GATT_IPSP_UUID);
a = attribute_find(adapter, &uuid);
- if (!a) {
+ if (!a && a->handle != NULL) {
error("Attribute not found for handle 0x%04x", a->handle);
return FALSE;
}
@@ -1051,7 +1051,7 @@ struct btd_attribute *btd_gatt_add_char(const bt_uuid_t *uuid,
fail:
#ifdef __TIZEN_PATCH__
/* Fix : RESOURCE_LEAK */
- if (char_decl->path)
+ if (char_decl != NULL && char_decl->path != NULL)
g_free(char_decl->path);
if (char_decl)
free(char_decl);