mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-02-21 16:08:31 +00:00
Minor changes
This commit is contained in:
parent
50be50cf6a
commit
e0afbb647b
@ -113,13 +113,14 @@ bool MagiskInit::patch_sepolicy(const char *file) {
|
|||||||
for (dirent *entry; (entry = xreaddir(dir.get()));) {
|
for (dirent *entry; (entry = xreaddir(dir.get()));) {
|
||||||
auto rule = custom_rules_dir + "/" + entry->d_name + "/sepolicy.rule";
|
auto rule = custom_rules_dir + "/" + entry->d_name + "/sepolicy.rule";
|
||||||
if (access(rule.data(), R_OK) == 0) {
|
if (access(rule.data(), R_OK) == 0) {
|
||||||
LOGD("Loading custom sepolicy patch: %s\n", rule.data());
|
LOGD("Loading custom sepolicy patch: [%s]\n", rule.data());
|
||||||
sepol->load_rule_file(rule.data());
|
sepol->load_rule_file(rule.data());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LOGD("Dumping sepolicy to: [%s]\n", file);
|
||||||
sepol->to_file(file);
|
sepol->to_file(file);
|
||||||
delete sepol;
|
delete sepol;
|
||||||
|
|
||||||
|
@ -566,7 +566,7 @@ run_migrations() {
|
|||||||
|
|
||||||
copy_sepolicy_rules() {
|
copy_sepolicy_rules() {
|
||||||
# Remove all existing rule folders
|
# Remove all existing rule folders
|
||||||
rm -rf /data/unencrypted/magisk /metadata/magisk /persist/magisk /mnt/vendor/persist/magisk
|
rm -rf /data/unencrypted/magisk /cache/magisk /metadata/magisk /persist/magisk /mnt/vendor/persist/magisk
|
||||||
|
|
||||||
# Find current active RULESDIR
|
# Find current active RULESDIR
|
||||||
local RULESDIR
|
local RULESDIR
|
||||||
|
Loading…
x
Reference in New Issue
Block a user