|
Message-Id: <20221021215124.31215-1-ismael@iodev.co.uk> Date: Fri, 21 Oct 2022 23:51:24 +0200 From: Ismael Luceno <ismael@...ev.co.uk> To: musl@...ts.openwall.com Cc: Rich Felker <dalias@...c.org>, Ismael Luceno <ismael@...ev.co.uk> Subject: [PATCH] nftw: Fix clobbering of errno Signed-off-by: Ismael Luceno <ismael@...ev.co.uk> --- src/misc/nftw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/misc/nftw.c b/src/misc/nftw.c index 8dcff7fefd2a..5b233b2b8e77 100644 --- a/src/misc/nftw.c +++ b/src/misc/nftw.c @@ -93,8 +93,8 @@ static int do_nftw(char *path, int (*fn)(const char *, const struct stat *, int, || (de->d_name[1]=='.' && !de->d_name[2]))) continue; if (strlen(de->d_name) >= PATH_MAX-l) { - errno = ENAMETOOLONG; closedir(d); + errno = ENAMETOOLONG; return -1; } path[j]='/'; -- 2.38.1
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.