From 124ce421d039831a0f8c9016047ca10b0da52162 Mon Sep 17 00:00:00 2001 From: "Andrey M. Borodin" Date: Sun, 5 Feb 2023 10:28:04 -0800 Subject: [PATCH v9 2/2] Fix oversight for compression of last 4 bytes --- src/common/pg_lzcompress.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/pg_lzcompress.c b/src/common/pg_lzcompress.c index bc85327af0..aea262dad2 100644 --- a/src/common/pg_lzcompress.c +++ b/src/common/pg_lzcompress.c @@ -512,7 +512,7 @@ pglz_compress(const char *source, int32 slen, char *dest, uint16 hist_idx; const unsigned char *src_ptr = (const unsigned char *) source; const unsigned char *src_end = (const unsigned char *) source + slen; - const unsigned char *compress_src_end = src_end - 4; + const unsigned char *compress_src_end = src_end; unsigned char control_dummy = 0; unsigned char *control_ptr = &control_dummy; unsigned char control_byte = 0; -- 2.32.0 (Apple Git-132)