File: mount.patch

package info (click to toggle)
hurd 1%3A0.9.git20251029-1
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 37,152 kB
  • sloc: ansic: 539,358; sh: 5,143; asm: 2,998; makefile: 2,303; perl: 589; pascal: 484; awk: 157
file content (21 lines) | stat: -rw-r--r-- 715 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
mount: Ignore `loop' and `exec' options

* utils/mount.c (do_mount): Ignore `loop' and `exec' options.
---
 mount.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/utils/mount.c b/utils/mount.c
index 8b059c2..8af055e 100644
--- a/utils/mount.c
+++ b/utils/mount.c
@@ -284,7 +284,9 @@ do_mount (struct fs *fs, int remount)
       {
 	ARGZ (add (&fsopts, &fsopts_len, o));
       }
-    else if ((strcmp (o, "defaults") != 0) && (strlen (o) != 0))
+    else if ((strcmp (o, "defaults") != 0) && (strlen (o) != 0) &&
+	     strcmp (o, "loop") != 0 &&
+	     strcmp (o, "exec") != 0)
       {
 	/* Prepend `--' to the option to make a long option switch,
 	   e.g. `--ro' or `--rsize=1024'.  */