[PATCH] in headset_init(), it's possible that hs->hfp_handle is not set, so we should not check hs->hfp_handle in headset_connect_cb()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We found this bug when developing the HFP plugin for telephonyd.

---
 audio/headset.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/audio/headset.c b/audio/headset.c
index 9f6b736..9b9be17 100644
--- a/audio/headset.c
+++ b/audio/headset.c
@@ -1304,8 +1304,7 @@ void headset_connect_cb(GIOChannel *chan, GError *err, gpointer user_data)
 	else
 		hs->auto_dc = FALSE;
 
-	if (server_is_enabled(&dev->src, HANDSFREE_SVCLASS_ID) &&
-			hs->hfp_handle != 0)
+	if (server_is_enabled(&dev->src, HANDSFREE_SVCLASS_ID))
 		hs->hfp_active = TRUE;
 	else
 		hs->hfp_active = FALSE;
-- 
1.5.4.5

--
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

[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux