From: Yu Watanabe Date: Sat, 11 Aug 2018 13:47:22 +0000 (+0900) Subject: util: improve comments why we ignore EACCES and EPERM X-Git-Tag: v240~831 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=53c442ef634ecc0e29de046a2c39114013004a57;p=thirdparty%2Fsystemd.git util: improve comments why we ignore EACCES and EPERM Follow-up for ef454fd1936813fa45d3e3b459d43fa30be7bf49 (#9848). --- diff --git a/src/basic/mount-util.c b/src/basic/mount-util.c index 62f1ed4d746..1f9590ccb6a 100644 --- a/src/basic/mount-util.c +++ b/src/basic/mount-util.c @@ -544,7 +544,14 @@ int bind_remount_recursive_with_mountinfo(const char *prefix, bool ro, char **bl if (IN_SET(r, 0, -ENOENT)) continue; if (IN_SET(r, -EACCES, -EPERM)) { - /* Even if root user invoke this, FUSE or NFS mount points may not be acceessed. */ + /* Even if root user invoke this, submounts under private FUSE or NFS mount points + * may not be acceessed. E.g., + * + * $ bindfs --no-allow-other ~/mnt/mnt ~/mnt/mnt + * $ bindfs --no-allow-other ~/mnt ~/mnt + * + * Then, root user cannot access the mount point ~/mnt/mnt. + * In such cases, the submounts are ignored, as we have no way to manage them. */ log_debug_errno(r, "Failed to determine '%s' is mount point or not, ignoring: %m", x); continue; }