pbap: Fix crash if phone log is empty
authorJaganath Kanakkassery <jaganath.k@samsung.com>
Fri, 22 Mar 2013 10:19:37 +0000 (15:49 +0530)
committerDoHyun Pyun <dh79.pyun@samsung.com>
Mon, 22 Apr 2013 04:14:16 +0000 (13:14 +0900)
commitbdab0e6bd359ef59cf94f63e43d4e4144898aea7
treee8e2d61df3846e76ea8f7eb67767902b19f22b69
parent159aa9b83dd55285339ff9645be05956f2298fb9
pbap: Fix crash if phone log is empty

In __bluetooth_pb_get_phone_log_list() if phone log is empty then
contacts_list_first() fails and it frees query. But since caller is
also freeing query double free happens.

Change-Id: If97d2eae0005bab128c0c0ee01697f911f04e41e
pb-agent/bluetooth_pb_agent.c