Android M reflection method freeStorageAndNotify exception

前端 未结 2 1623
抹茶落季
抹茶落季 2020-12-09 10:43

I\'m using reflection method freeStorageAndNotify:

Method freeStorageAndNotify = null;
freeStorageAndNotify = service.packageManager.getClass().getMethod(
           


        
2条回答
  •  無奈伤痛
    2020-12-09 11:08

    Refer to these pages: permissions by protection level and protection level definitions.

    android.permission.CLEAR_APP_CACHE

    This falls under the protection level "signature|privileged" which means that only same-signature or privileged apps (system signed basically) can have this permission.

    Also you should check out the Behavior Changes in general.

提交回复
热议问题