Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Jun 2001 08:56:51 +0200
From:      "Steve O'Hara-Smith" <steveo@eircom.net>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        david@catwhisker.org, current@FreeBSD.ORG
Subject:   Re: symlink(2) [Was: Re: tcsh.cat]
Message-ID:  <20010616085651.29684596.steveo@eircom.net>
In-Reply-To: <Pine.BSF.4.21.0106161355360.89789-100000@besplex.bde.org>
References:  <20010615183515.36f81380.steveo@eircom.net> <Pine.BSF.4.21.0106161355360.89789-100000@besplex.bde.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 16 Jun 2001 14:34:07 +1000 (EST)
Bruce Evans <bde@zeta.org.au> wrote:

BE> We are (or at least I am) talking about changing it to prevent links to a
BE> string that can _never_ be a valid pathname.  Fortunately, in POSIX there
BE> is only one such string (the empty string).

	Maybe, but it seems a harmless special case to me, and others seem to
find it useful.

BE> Here's an example of a standard utility being clueless about symlinks to
BE> nothing:
BE> 
BE>     $ ln -s '' foo
BE>     $ cp foo bar
BE>     cp: foo is a directory (not copied)

	That *is* broken, it should make bar a symlink to '' IMHO.

BE> cp is also broken for symlinks to valid pathnames for nonexistent files;
BE> 
BE>     $ rm -f foo
BE>     $ ln -s /nonesuch foo
BE>     $ cp foo bar
BE> 
BE> This duplicates foo as a symlink, but should just fail.

	This is correct behaviour IMHO - why on earth should it fail. If I
copy a directory containing symlinks I don't want them do vanish just because
the target is unavailable.

-- 
    Directable Mirrors - A Better Way To Focus The Sun

	 	        http://www.best.com/~sohara

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010616085651.29684596.steveo>