opentok-android-sdk-samples
opentok-android-sdk-samples copied to clipboard
Calling crashes on Android 12 with error regarding BLUETOOTH_CONNECT permission. Log trace in comments
Fatal Exception: java.lang.SecurityException: Need android.permission.BLUETOOTH_CONNECT permission for android.content.AttributionSource@a0cbd704: HeadsetService at android.os.Parcel.createExceptionOrNull(Parcel.java:2425) at android.os.Parcel.createException(Parcel.java:2409) at android.os.Parcel.readException(Parcel.java:2392) at android.os.Parcel.readException(Parcel.java:2334) at android.bluetooth.IBluetoothHeadset$Stub$Proxy.getConnectedDevicesWithAttribution(IBluetoothHeadset.java:1040) at android.bluetooth.BluetoothHeadset.getConnectedDevices(BluetoothHeadset.java:549) at com.opentok.android.DefaultAudioDevice$6.onServiceConnected(:22) at android.bluetooth.BluetoothHeadset$3.handleMessage(BluetoothHeadset.java:1422) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loopOnce(Looper.java:201) at android.os.Looper.loop(Looper.java:288) at android.app.ActivityThread.main(ActivityThread.java:7842) at java.lang.reflect.Method.invoke(Method.java) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1003)
Thanks, @salmanjawedfolio, for filing this issue.
Closing, since this has been fixed by newer versions of the SDK. If you're still able to reproduce using the most recent version, please file another issue. Thanks!