"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: plug a few fd leaks in fdopen() error paths
To:
Omar Polo <op@omarpolo.com>
Cc:
gameoftrees@openbsd.org
Date:
Tue, 30 Jan 2024 15:01:35 +0100

Download raw body.

Thread
On Tue, Jan 30, 2024 at 01:04:41PM +0100, Omar Polo wrote:
> did a sweep of the error paths of fdopen/dir and spotted these.

Well spotted! ok.

> The got-read-blob.c change, which I'd commit separately if ok, is only a
> style change: I think that if (fp...) else if (close(fd)) construct
> tricked my eyes at least twice, and while it is correct, I prefer if it
> were more like the the other code we have around.

Yes, seems better.