Remove useless LZ4 system call on failure when writing file header
Michael Paquier <michael@paquier.xyz>
Remove useless LZ4 system call on failure when writing file header If an error occurs when writing the LZ4 file header, LZ4F_compressEnd() was called in the error code path of write(), followed by LZ4F_freeCompressionContext() to finish the cleanup. The code as-is was not broken, but the LZ4F_compressEnd() proves to not be necessary as there are no contents to flush at this stage, so remove it. Per gripe from Jeevan Ladhe and Robert Haas. Discussion: https://postgr.es/m/CAOgcT0PE33wbD7giAT1OSkNJt=p-vu8huq++qh=ny9O=SCP5aA@mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/bin/pg_basebackup/walmethods.c | modified | +0 −1 |
Discussion
- Teach pg_receivewal to use lz4 compression 55 messages · 2021-06-29 → 2022-03-18