This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, HURD]: null pathnames shall return ENOENT


> Looking more closely, the reason why chdir and chroot append "/."
> themselves is that contrary to __hurd_file_name_lookup which only
> appends "/", "/." also checks for search permission, see the comment
> 
>   /* Append trailing "/." to directory name to force ENOTDIR if it's not a
>      directory and EACCES if we don't have search permission.  */
> 
> So we really need to append "/." here, but still not when the path is null.

Oh, I see.  It still would be better to give _hurd_change_directory_port a
flag about calling reparent, and consolidate that magic to the one place.

Thanks,
Roland


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]