You've already forked ZygiskNext
mirror of
https://github.com/Dr-TSNG/ZygiskNext.git
synced 2025-08-27 23:46:34 +00:00
show root impl
This commit is contained in:
@@ -25,10 +25,15 @@ fn start() {
|
||||
} else if args.len() == 2 && args[1] == "version" {
|
||||
println!("Zygisk Next daemon {}", ZKSU_VERSION);
|
||||
return;
|
||||
} else if args.len() == 2 && args[1] == "root" {
|
||||
root_impl::setup();
|
||||
println!("root impl: {:?}", root_impl::get_impl());
|
||||
return;
|
||||
}
|
||||
|
||||
utils::switch_mount_namespace(1).expect("switch mnt ns");
|
||||
root_impl::setup();
|
||||
log::info!("current root impl: {:?}", root_impl::get_impl());
|
||||
zygiskd::main().expect("zygiskd main");
|
||||
}
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ pub fn uid_granted_root(uid: i32) -> bool {
|
||||
match get_impl() {
|
||||
RootImpl::KernelSU => kernelsu::uid_granted_root(uid),
|
||||
RootImpl::Magisk => magisk::uid_granted_root(uid),
|
||||
_ => unreachable!(),
|
||||
_ => panic!("uid_granted_root: unknown root impl {:?}", get_impl()),
|
||||
}
|
||||
}
|
||||
|
||||
@@ -53,6 +53,6 @@ pub fn uid_should_umount(uid: i32) -> bool {
|
||||
match get_impl() {
|
||||
RootImpl::KernelSU => kernelsu::uid_should_umount(uid),
|
||||
RootImpl::Magisk => magisk::uid_should_umount(uid),
|
||||
_ => unreachable!(),
|
||||
_ => panic!("uid_should_umount: unknown root impl {:?}", get_impl()),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user