Prefer "to be modified" over "to be opened for writing".

This is quite tricky situation, because we allow to open a file with
O_RDONLY|O_TRUNC. O_TRUNC modifies a file, but we actually don't open
it for writing. EISDIR is also returned when we try to open a directory
O_RDONLY|O_TRUNC, which is correct.
POSIX says that "The result of using O_TRUNC with O_RDONLY is undefined.",
we choose to accept it (Solaris did the same), that's why "to be modified"
seems more accurate to me.
This commit is contained in:
Pawel Jakub Dawidek 2007-01-07 17:32:16 +00:00
parent d19e3538ae
commit 6a8780971a

View File

@ -238,7 +238,7 @@ does not permit writing.
Too many symbolic links were encountered in translating the pathname.
.It Bq Er EISDIR
The named file is a directory, and the arguments specify
it is to be opened for writing.
it is to be modified.
.It Bq Er EROFS
The named file resides on a read-only file system,
and the file is to be modified.