Vincent Lefevre wrote, on 25 Nov 2021:
>
> https://austingroupbugs.net/view.php?id=1488 about pwd and
> CONSEQUENCES OF ERRORS considers ENOSPC only.
>
> But are there other errors that may yield a partial write?
> I'm thinking of EFBIG and EPIPE, in particular.
Good point. The discussion that spawned bug 1488 had centred around
ENOSPC, so I suppose that's why I singled it out in my proposed
changes. There are certainly other ways to get a partial write.
The write() page says:
If a write() requests that more bytes be written than there is
room for (for example, the file size limit of the process or the
physical end of a medium), only as many bytes as there is room for
shall be written.
I think the simplest solution would be for bug 1488 resolution to
say "an error condition" instead of "an [ENOSPC] condition".
I will reopen it and put in a new proposed resolution.
--
Geoff Clare
The Open Group, Apex Plaza, Forbury Road, Reading, RG1 1AX, England