From: Theo Buehler Subject: Re: Remove inconsistent NULL check in ffs_realloccg To: Rafael Sadowski Cc: tech@openbsd.org Date: Fri, 19 Sep 2025 23:17:53 +0200 On Fri, Sep 19, 2025 at 10:30:35PM +0200, Rafael Sadowski wrote: > ffs_realloccg() always sets *bpp to NULL at the start, so checking bpp > != NULL later is unnecessary. Remove the useless check. This doesn't look right. I don't know much about ffs interna but... Currently a caller can do ffs_realloccg(..., NULL, blknop) if it doesn't care about the bpp or it can do ffs_realloccg(..., &bp, blocknop) with an uninitialized struct buf *bp and the function will initialize it whether it succeeds or not. Your diff breaks callers of the first kind.