]> git.ipfire.org Git - thirdparty/util-linux.git/commit
libmount: allow --read-only for not-root users
authorKarel Zak <kzak@redhat.com>
Mon, 25 Jan 2021 10:11:05 +0000 (11:11 +0100)
committerKarel Zak <kzak@redhat.com>
Mon, 25 Jan 2021 10:11:05 +0000 (11:11 +0100)
commit7b78b571b7907d98a53dd74c5325249c2057e7b4
treebdd590648a20c55c22e502d73e8e7ea29bcf8613
parent34a58c05a7260370d6238bb3d1c29938a9a31f9b
libmount: allow --read-only for not-root users

The command "mount -r" was supported for non-root users in very old
mount(8) versions. Unfortunately, in this case libmount replaces all
mount options from command line by options from fstab. We need
exception for MS_RDONLY.

Fixes: https://github.com/karelzak/util-linux/issues/1235
Signed-off-by: Karel Zak <kzak@redhat.com>
libmount/src/context.c