On 9/16/23 10:45, Ingo Schwarze wrote:
That diff is certainly not OK.
It is misleading because a "path" argument pointing to a file
that is not a directory is actually valid.

The problem only occurs when you add a trailing slash to the name
of a file that is not a directory, like this:

Yes, which is what the example program I wrote showed. I chose brevity
over accuracy when providing an example description, but I'm all for
more accurate descriptions.
Looking at sys_unveil in /sys/kern/vfs_syscalls.c, i suspect that
errno actually comes from a lower layer, likely namei(9), rather than
from unveil(2) itself.

That is also true for EFAULT which is described. I also noticed that
EACCESS is returned on line 698, but it too is missing in the list of
errors.

Reply via email to