diff options
| author | Andrei Vagin <avagin@google.com> | 2024-05-08 15:26:42 -0700 |
|---|---|---|
| committer | Aleksandr Nogikh <nogikh@google.com> | 2024-05-09 07:49:18 +0000 |
| commit | 804e5bd862bec2c4d0d84ad8291ab8d5db7715c3 (patch) | |
| tree | b4be516d932206c234298d206ce5d61b26c31cdf | |
| parent | 20bf80e1d6eb340a35a841a099b8dca81e42ff5e (diff) | |
executor: setup binfmt_mist only if it has been mounted
gVisor doesn't implement binfmt file system.
Fixes: 229488b413d4 ("executor: consistently fail on feature setup")
Signed-off-by: Andrei Vagin <avagin@google.com>
| -rw-r--r-- | executor/common_linux.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/executor/common_linux.h b/executor/common_linux.h index 6b5fcad71..cb554b364 100644 --- a/executor/common_linux.h +++ b/executor/common_linux.h @@ -4988,6 +4988,7 @@ static void setup_binfmt_misc() { if (mount(0, "/proc/sys/fs/binfmt_misc", "binfmt_misc", 0, 0)) { debug("mount(binfmt_misc) failed: %d\n", errno); + return; } if (!write_file("/proc/sys/fs/binfmt_misc/register", ":syz0:M:0:\x01::./file0:") || !write_file("/proc/sys/fs/binfmt_misc/register", ":syz1:M:1:\x02::./file0:POC")) |
