Re: [PATCH v2] mount: detect when kernel silently adds MS_RDONLY flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 21, 2010 at 03:19:31PM +0200, Petr Uzel wrote:

 Thanks, applied with a small change:

> +  /* Kernel can silently add MS_RDONLY flag when mounting file system that
> +   * does not have write support. Check this to avoid 'ro' in /proc/mounts 
> +   * and 'rw' in mtab.
> +   */
> +  if (!fake && mnt5_res == 0 &&
> +      !(flags & MS_RDONLY) && is_readonly(node)) {

  +      !(flags & (MS_RDONLY | MS_PROPAGATION | MS_MOVE)) &&
  +      is_readonly(node)) {

 is probably better. 

    Karel

-- 
 Karel Zak  <kzak@xxxxxxxxxx>
 http://karelzak.blogspot.com
--
To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux