Fix /proc/mounts for autofs(5) mounts.
MFC after: 2 weeks Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
36c03d045a
commit
e55366be83
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=351822
@ -462,6 +462,15 @@ linprocfs_domtab(PFS_FILL_ARGS)
|
|||||||
else if (strcmp(fstype, "procfs") == 0)
|
else if (strcmp(fstype, "procfs") == 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (strcmp(fstype, "autofs") == 0) {
|
||||||
|
/*
|
||||||
|
* FreeBSD uses eg "map -hosts", whereas Linux
|
||||||
|
* expects just "-hosts".
|
||||||
|
*/
|
||||||
|
if (strncmp(mntfrom, "map ", 4) == 0)
|
||||||
|
mntfrom += 4;
|
||||||
|
}
|
||||||
|
|
||||||
if (strcmp(fstype, "linsysfs") == 0) {
|
if (strcmp(fstype, "linsysfs") == 0) {
|
||||||
sbuf_printf(sb, "/sys %s sysfs %s", mntto,
|
sbuf_printf(sb, "/sys %s sysfs %s", mntto,
|
||||||
sp->f_flags & MNT_RDONLY ? "ro" : "rw");
|
sp->f_flags & MNT_RDONLY ? "ro" : "rw");
|
||||||
|
Loading…
Reference in New Issue
Block a user