| To: | yyyyyyyyyyyyyyy@xxxxxxxxxxxxx |
|---|---|
| Subject: | Defect in XCU ln |
| From: | yyyyyy@xxxxxxxxxxx |
| Date: | Thu, 24 Jun 2004 21:07:33 +0100 (BST) |
Defect report from : Paul Eggert , UCLA
(Please direct followup comments direct to yyyyyyyyyyyyyy@xxxxxxxxxxxxx)
@ page 549 line 21190 section ln objection {20040624a}
Problem:
Edition of Specification (Year): 2004
Defect code : 1. Error
POSIX currently requires "ln -f a b" to remove "b" even if the
underlying link() function fails. It should not require this.
That is POSIX should allow implementations where "ln -f a b"
does not remove "b" upon failure.
Here are some examples of the problem.
* Suppose /a/f and /b/f are two files on different file systems and
the implementation does not support links between file systems. POSIX
currently requires the command "ln -f /a/f /b/f" to remove /b/f and
then fail.
* Suppose d1/d is a directory, d2/d is a file, and the process does not
have appropriate privileges. POSIX currently requires the command
"ln d1/d d2" to remove d2/d and then fail.
* Suppose a_very_long_name is too long for the current
file system and the regular file f exists. POSIX currently requires
"ln -s a_very_long_name f" to remove f and then fail.
* Suppose a does not exist but b does. Then POSIX requires
"ln -f a b" to remove b.
In all these cases, POSIX should allow "ln" to fail without removing
the target. (Ideally, POSIX should require "ln" to fail without
removing its target, but such a requirement would invalidate many
existing implementations so I'm not proposing it here.)
Action:
Insert the following text at the start of step (1b) in XCU page 549
line 21190.
(This step may be omitted unless the actions described in
steps (2) through (4) would fail with errno set to EEXIST.)
Insert the following text in the ln rationale, after XCU page 551
line 21279:
Earlier versions of this standard required "ln -f a b" to remove
b even if the underlying link() function failed. This behavior
is no longer required: "ln -f a b" is now allowed to fail
without removing b.
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Defect in XSH sighold, Geoff Clare |
|---|---|
| Next by Date: | Defect in XSH pthread_mutex_lock, sebastien.decugis |
| Previous by Thread: | Defect in XSH exit, _Exit, _exit -- terminate a process, terekhov |
| Next by Thread: | Defect in XCU ln, lmayer |
| Indexes: | [Date] [Thread] [All Lists] |