[PATCH v2] linux: Fix __closefrom_fallback iterates until max int (BZ#28993)

Andreas Schwab schwab@linux-m68k.org
Thu Mar 24 11:19:46 GMT 2022


On Mär 24 2022, Adhemerval Zanella via Libc-alpha wrote:

>    if (dirfd == -1)
>      {
>        /* The closefrom should work even when process can't open new files.  */
> -      if (errno == ENOENT || !dirfd_fallback)
> -        goto err;
> +      if (errno != EMFILE || !dirfd_fallback)

There is also ENFILE.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."


More information about the Libc-alpha mailing list