From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx> --- android/handsfree.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/android/handsfree.c b/android/handsfree.c index 33fcbdd..9a2fdd0 100644 --- a/android/handsfree.c +++ b/android/handsfree.c @@ -2904,14 +2904,18 @@ static void disable_sco_server(void) static void bt_sco_get_fd(const void *buf, uint16_t len) { - int fd; - GError *err; + const struct sco_cmd_get_fd *cmd = buf; struct sco_rsp_get_fd rsp; struct hf_device *dev; + bdaddr_t bdaddr; + GError *err; + int fd; DBG(""); - dev = find_default_device(); + android2bdaddr(cmd->bdaddr, &bdaddr); + + dev = find_device(&bdaddr); if (!dev || !dev->sco) goto failed; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html