]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Add more tests for corrupted data with pglz_decompress()
authorMichael Paquier <michael@paquier.xyz>
Wed, 13 May 2026 05:43:46 +0000 (14:43 +0900)
committerMichael Paquier <michael@paquier.xyz>
Wed, 13 May 2026 05:43:46 +0000 (14:43 +0900)
commit89192080f0a9599d121a8ba85a94b41b8c424cf5
tree72685a3db3a5ca0d9ccc21dd2117f69955f465e7
parentd9cd9b4d7e147fc4965195c765f191ac69593c43
Add more tests for corrupted data with pglz_decompress()

Two cases fixed by 2b5ba2a0a141 were not covered, to emulate the
handling of corrupted data, for:
- set control bit with a valid 2-byte match tag where offset is 0.
- set control bit with a valid 2-byte match tag where offset exceeds
output written.

Oversight in 67d318e70402.

Reviewed-by: Ayush Tiwari <ayushtiwari.slg01@gmail.com>
Discussion: https://postgr.es/m/agF4xkIdRcrCIprs@paquier.xyz
Backpatch-through: 14
src/test/regress/expected/compression_pglz.out
src/test/regress/sql/compression_pglz.sql