From 06af1c0ede225d269e0e2753cdb7a709120b9358 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Thu, 10 Nov 2016 21:50:04 -0500 Subject: [PATCH] Respect force_mount_namespace in MountEmulatedStorage(). In Ieb75cc3009ed26b7366213409d5fad836f597084, the unshare step was skipped if no storage is required. But the change failed to take the force parameter into account Test: m Test: angler boots Test: fugu boots Bug: 21643067 Change-Id: I52447f02fd25f553628564733fd6bf2523c07f7c --- core/jni/com_android_internal_os_Zygote.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/jni/com_android_internal_os_Zygote.cpp b/core/jni/com_android_internal_os_Zygote.cpp index 3e111c01c1dac..ca0970850ef12 100644 --- a/core/jni/com_android_internal_os_Zygote.cpp +++ b/core/jni/com_android_internal_os_Zygote.cpp @@ -304,7 +304,7 @@ static bool MountEmulatedStorage(uid_t uid, jint mount_mode, storageSource = "/mnt/runtime/read"; } else if (mount_mode == MOUNT_EXTERNAL_WRITE) { storageSource = "/mnt/runtime/write"; - } else { + } else if (!force_mount_namespace) { // Sane default of no storage visible return true; }