Permission Denial: startActivity asks to run as user -2 but is calling from user 0; this requires android.permission.INTERACT_ACROSS_USERS_FULL

前端 未结 5 931
遥遥无期
遥遥无期 2020-12-01 18:38

When I\'m trying to use android \'am\' command to start an activity ,it\'s wrong under 4.2 platform(I tried , it\'s ok under 2.3 version).The code is like this



        
5条回答
  •  离开以前
    2020-12-01 18:51

    Permissions are just a line of code that you need to add in the manifest to inform that you accessing those resources and requesting android to allow these resources to use. enter image description here

    1) i just added an example containing permission.

    2) In Linux there is root user ,group and others . 0 comes to root and UID cannot be negative its value is between 0 - 999. See this link

提交回复
热议问题