CustomSystemService
CustomSystemService copied to clipboard
在 Android 8.1 上会抛出 SecurityException
在 Android 8.1 上 addService 的时候会失败,似乎是 selinux 阻止了此操作。
E/SELinux: avc: denied { add } for service=xxx pid=4629 uid=1000 scontext=u:r:system_server:s0 tcontext=u:object_r:default_android_service:s0 tclass=service_manager permissive=0 E/ServiceManager: add_service('xxx',16) uid=1000 - PERMISSION DENIED