From a7cfbb92a646fbd83cd3891226193906a006708f Mon Sep 17 00:00:00 2001 From: Wiktor Garbacz Date: Wed, 9 Oct 2019 02:47:13 -0700 Subject: [PATCH] Remove uneeded read-only remount Caused failures if root is mounted as nodev, nosuid etc. Root is pivoted and unmounted right after this anyhow. PiperOrigin-RevId: 273707731 Change-Id: I75f1edaf2877c096e4f5bb7dc1b2bb8eb5c437a3 --- sandboxed_api/sandbox2/namespace.cc | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sandboxed_api/sandbox2/namespace.cc b/sandboxed_api/sandbox2/namespace.cc index d0664ce..99916b0 100644 --- a/sandboxed_api/sandbox2/namespace.cc +++ b/sandboxed_api/sandbox2/namespace.cc @@ -73,10 +73,6 @@ void PrepareChroot(const Mounts& mounts) { // Walk the tree and perform all the mount operations. mounts.CreateMounts(kSandbox2ChrootPath); - - SAPI_RAW_PCHECK( - mount("/", "/", "", MS_BIND | MS_REMOUNT | MS_RDONLY, nullptr) != -1, - "Remounting / RO failed"); } void TryDenySetgroups() {