获取手机是否root信息

 private String isRoot(){

        String bool = "Root:false";

        try{

            if ((!new File("/system/bin/su").exists()) && (!new File("/system/xbin/su").exists())){

                bool = "Root:false";

            } else {

                bool = "Root:true";

            }

        } catch (Exception e) {

        }

        return bool;

    }

posted @ 2017-12-20 11:55  小白look世界  阅读(306)  评论(0编辑  收藏  举报