首页 > 解决方案 > SecurityException: android.permission.INTERACT_ACROSS_USERS 缺少蓝牙访问

问题描述

尝试执行以下操作时在非系统应用程序上遇到此问题:“BluetoothAdapter::getProfileProxy”。仅在 android 8.1 上观察到,但不可重现。

Caused by: java.lang.SecurityException: query intent receivers: Neither user 15010171 nor current process has android.permission.INTERACT_ACROSS_USERS.
at android.os.Parcel.readException(Parcel.java:2021)
at android.os.Parcel.readException(Parcel.java:1967)
at android.content.pm.IPackageManager$Stub$Proxy.queryIntentServices(IPackageManager.java:4830)
at android.app.ApplicationPackageManager.queryIntentServicesAsUser(ApplicationPackageManager.java:1255)
at android.content.Intent.resolveSystemServiceAsUser(Intent.java:8365)
at android.bluetooth.BluetoothA2dp.doBind(BluetoothA2dp.java:432)
at android.bluetooth.BluetoothA2dp.<init>(BluetoothA2dp.java:405)
at android.bluetooth.BluetoothAdapter.getProfileProxy(BluetoothAdapter.java:3034) 

问题:

想知道是否有人可以解释这个问题。

标签: androidandroid-permissionsandroid-bluetooth

解决方案


推荐阅读