aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/release/3.4.8
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2023-07-12 13:47:49 +0200
committerCorinna Vinschen <corinna@vinschen.de>2023-07-26 15:14:33 +0200
commitf48ce81122d4be42c3679dade5724d734091129e (patch)
tree0698c5f946453548f801bcdbe6959a12d890805f /winsup/cygwin/release/3.4.8
parent00510919993da49cf91421fe13242a7d8a82c1fd (diff)
downloadnewlib-f48ce81122d4be42c3679dade5724d734091129e.zip
newlib-f48ce81122d4be42c3679dade5724d734091129e.tar.gz
newlib-f48ce81122d4be42c3679dade5724d734091129e.tar.bz2
Cygwin: Fix and streamline AT_EMPTY_PATH handling
The GLIBC extension AT_EMPTY_PATH allows the functions fchownat and fstatat to operate on dirfd alone, if the given pathname is an empty string. This also allows to operate on any file type, not only directories. Commit fa84aa4dd2fb4 broke this. It only allows dirfd to be a directory in calls to these two functions. Fix that by handling AT_EMPTY_PATH right in gen_full_path_at. A valid dirfd and an empty pathname is now a valid combination and, noticably, this returns a valid path in path_ret. That in turn allows to remove the additional path generation code from the callers. Fixes: fa84aa4dd2fb ("Cygwin: fix errno values set by readlinkat") Reported-by: Johannes Schindelin <johannes.schindelin@gmx.de> Tested-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/cygwin/release/3.4.8')
0 files changed, 0 insertions, 0 deletions