diff options
author | Jonathan Aillet <jonathan.aillet@iot.bzh> | 2018-09-12 17:48:05 +0200 |
---|---|---|
committer | Jonathan Aillet <jonathan.aillet@iot.bzh> | 2018-10-08 15:57:27 +0200 |
commit | def67c90db7f49311578a4cc34887b3e65666a27 (patch) | |
tree | 4e223755e80c8de0c7d7b57effffe5303a122ec0 | |
parent | 9f88b345bb8e4ccab4f2ab9a20c79802e9f9485e (diff) |
Prevent segfault when receiving request in Hal-Bt
Prevent segfault when receiving 'get_connected_bt_a2dp_devices'
and 'get_selected_bt_a2dp_device' requests in Hal-Bt plugin.
Change-Id: I1eb5dcab997ae77d8adc3cf28585c2449ec42a2e
Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
-rw-r--r-- | plugins/lib/bluetooth/hal-bt-cb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/lib/bluetooth/hal-bt-cb.c b/plugins/lib/bluetooth/hal-bt-cb.c index 82fc2ba..6ac9193 100644 --- a/plugins/lib/bluetooth/hal-bt-cb.c +++ b/plugins/lib/bluetooth/hal-bt-cb.c @@ -117,7 +117,7 @@ void HalBtGetA2DPBluetoothDevices(AFB_ReqT request) while(currentBtDeviceData) { wrap_json_pack(¤tBtDeviceObjectJ, - "{s:s s:s s:s s:b}", + "{s:s s:s s:s}", "Interface", currentBtDeviceData->hci, "Name", currentBtDeviceData->name, "Address", currentBtDeviceData->address); @@ -146,7 +146,7 @@ void HalBtGetSelectedA2DPBluetoothDevice(AFB_ReqT request) } wrap_json_pack(&selectedBtDeviceObject, - "{s:s s:s s:s s:b}", + "{s:s s:s s:s}", "Interface", localHalBtPluginData->selectedBtDevice->hci, "Name", localHalBtPluginData->selectedBtDevice->name, "Address", localHalBtPluginData->selectedBtDevice->address); |