diff options
author | Will Wang <wiwang@mozilla.com> | 2015-08-28 18:40:29 +0800 |
---|---|---|
committer | Szymon Janc <szymon.janc@gmail.com> | 2015-09-01 20:59:31 +0200 |
commit | 6a475553c4c66ed7f1fa66130ec06ffc3dee8b39 (patch) | |
tree | eda44c04e9a9befbe0d46603a97652188b82a777 /android/hal-handsfree.c | |
parent | eac1f5d9356684f5ce2a61dd236372606425a231 (diff) | |
download | bluez-6a475553c4c66ed7f1fa66130ec06ffc3dee8b39.tar.gz |
android/hal-handsfree: Fix missing HFP WBS callback
Diffstat (limited to 'android/hal-handsfree.c')
-rw-r--r-- | android/hal-handsfree.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/android/hal-handsfree.c b/android/hal-handsfree.c index 279b26a46..3847901a9 100644 --- a/android/hal-handsfree.c +++ b/android/hal-handsfree.c @@ -153,6 +153,16 @@ static void handle_nrec(void *buf, uint16_t len, int fd) #endif } +static void handle_wbs(void *buf, uint16_t len, int fd) +{ +#if ANDROID_VERSION >= PLATFORM_VER(5, 0, 0) + struct hal_ev_handsfree_wbs *ev = buf; + + if (cbs->wbs_cb) + cbs->wbs_cb(ev->wbs, (bt_bdaddr_t *) (ev->bdaddr)); +#endif +} + static void handle_chld(void *buf, uint16_t len, int fd) { struct hal_ev_handsfree_chld *ev = buf; @@ -289,6 +299,8 @@ static const struct hal_ipc_handler ev_handlers[] = { /* HAL_EV_HANDSFREE_HSP_KEY_PRESS */ { handle_hsp_key_press, false, sizeof(struct hal_ev_handsfree_hsp_key_press) }, + /* HAL_EV_HANDSFREE_WBS */ + { handle_wbs, false, sizeof(struct hal_ev_handsfree_wbs) }, }; static uint8_t get_mode(void) |