Backup original sepolicy db for LD_PRELOAD strategy

This commit is contained in:
Wang Han
2026-05-24 15:57:34 +08:00
committed by GitHub
parent 14ea5cfb4a
commit 7245c166c3
+3
View File
@@ -225,6 +225,9 @@ impl MagiskInit {
let mut sepol = SePolicy::from_file(preload_policy());
// Keep a copy of the original policy for future use
preload_policy().copy_to(MOCK_LOAD)?;
// Remove the files before loading the policy
preload_policy().remove()?;
preload_ack().remove()?;