> On Nov 11, 2026, at 17:48, Fujii Masao <[email protected]> wrote:
> 
> Hi,
> 
> I'd like to propose the attached patch to fix file descriptor and
> memory leaks when LZ4 compression finalization or the final write
> fails. Without this fix, repeated failures can cause these resources
> to accumulate.
> 
> Thoughts?
> 
> Regards,
> 
> -- 
> Fujii Masao
> <v1-0001-pg_receivewal-Fix-resource-leaks-and-error-report.patch>

I have a question about the fix in dir_close(). In the current code, r = 
close(df->fd);, then if r == 0, it will do some operations based on method, 
such as unlink tmppath. But this patch does:
```
(void) close(df->fd);
goto cleanup;
```

Which bypasses the operations for successful close(df->fd), is that intentional?

Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/






Reply via email to