Date: Tue, 19 Sep 06 18:01:15 PDT From: perryh@pluto.rain.com (Perry Hutchison) To: freebsd-hackers@freebsd.org Subject: Symlinks on read-only FS Message-ID: <10609200101.AA21405@pluto.rain.com>
next in thread | raw e-mail | index | archive | help
I've just noticed this, in ufs/ufs/ufs_vnops.c:ufs_access()
/*
* Disallow write attempts on read-only filesystems;
* unless the file is a socket, fifo, or a block or
* character device resident on the filesystem.
*/
if (mode & VWRITE) {
switch (vp->v_type) {
case VDIR:
case VLNK:
case VREG:
if (vp->v_mount->mnt_flag & MNT_RDONLY)
return (EROFS);
Is the inclusion of VLNK here correct? I would think that
only the target of the symlink should matter: if it happens
to point onto a writable FS, the fact that the symlink itself
is on a ROFS should not matter.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?10609200101.AA21405>
