您的位置:首页 > 移动开发 > Android开发

Android 判断设备是否Root

2014-04-24 18:49 141 查看
public static boolean isRoot() {

boolean root = false;

try {
if ((!new File("/system/bin/su").exists())
&& (!new File("/system/xbin/su").exists())) {
root = false;
} else {
root = true;
}

} catch (Exception e) {
}

return root;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: