Umount by tmpfs id

This commit is contained in:
vvb2060 2023-02-26 19:49:23 +08:00 committed by John Wu
parent 2a4aa95a6f
commit 7dbfba76bf

View File

@ -18,9 +18,8 @@ void revert_unmount() {
// Unmount dummy skeletons and MAGISKTMP
// since mirror nodes are always mounted under skeleton, we don't have to specifically unmount
for (auto &info: parse_mount_info("self")) {
if (info.target.starts_with(MAGISKTMP) || // things in magisktmp
info.root.starts_with("/adb/modules") || // module nodes
info.root.starts_with("/" INTLROOT)) { // skeleton
if (info.source == "magisk" || info.source == "worker" || // magisktmp tmpfs
info.root.starts_with("/adb/modules")) { // bind mount from data partition
targets.push_back(info.target);
}
}