> On Feb 6, 2022, at 20:07, Todd C. Miller <todd.mil...@sudo.ws> wrote:
> 
> Since the input is opened read-only I don't see the point in checking
> the fclose() return value.  However, if you are going to do so, you
> might as well combine it with the ferror() check.  E.g.
> 
>    if (ferror(fp) || fclose(fp) == EOF) {
>        warn("%s", name);
>        status = 1;
>    }

If we do that, we leak fp when there is an
input error.

Reply via email to