mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-22 16:07:39 +00:00
Only care about mount namespace isolating
This commit is contained in:
parent
7f4f95cf83
commit
b5d80a88d1
@ -153,7 +153,7 @@ DCL_HOOK_FUNC(int, fork) {
|
|||||||
// Unmount stuffs in the process's private mount namespace
|
// Unmount stuffs in the process's private mount namespace
|
||||||
DCL_HOOK_FUNC(int, unshare, int flags) {
|
DCL_HOOK_FUNC(int, unshare, int flags) {
|
||||||
int res = old_unshare(flags);
|
int res = old_unshare(flags);
|
||||||
if (g_ctx && res == 0) {
|
if (g_ctx && (flags & CLONE_NEWNS) != 0 && res == 0) {
|
||||||
if (g_ctx->flags[UNMOUNT_FLAG]) {
|
if (g_ctx->flags[UNMOUNT_FLAG]) {
|
||||||
revert_unmount();
|
revert_unmount();
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user