GNU bug report logs - #13447
ln "" foo gives misleading error message

Previous Next

Package: coreutils;

Reported by: Ken Irving <ken.irving <at> alaska.edu>

Date: Tue, 15 Jan 2013 08:32:01 UTC

Severity: normal

Tags: notabug

Done: Bob Proulx <bob <at> proulx.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Joerg Schilling <Joerg.Schilling <at> fokus.fraunhofer.de>
Cc: jim <at> meyering.net, austin-group-l <at> opengroup.org, 13447 <at> debbugs.gnu.org, ken.irving <at> alaska.edu, bob <at> proulx.com, eblake <at> redhat.com
Subject: bug#13447: ln "" foo gives misleading error message
Date: Wed, 16 Jan 2013 09:58:20 -0800
On 01/16/13 03:07, Joerg Schilling wrote:
> If the symlink target is to be treated as a list of path name components, 
> I would expect ENOENT with an attempt to open() or stat() "a/".
> 
> If the symlink target is treated as a string that is concatenated to the 
> previous path, Solaris could be seen as correct.

Except that Solaris also treats the symlink as "." even if there is
no previous path.  For example, on Solaris 11:

$ ln -s '' empty
$ ls -l empty
lrwxrwxrwx   1 eggert   faculty        0 Jan 16 09:56 empty -> 
$ cat empty
cat: input error on empty: Is a directory
$ cat ''
cat: cannot open : No such file or directory

This is an undesirable inconsistency, and it's hard to see how
any user would want this behavior.




This bug report was last modified 12 years and 189 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.