Skip to content

seekable_format: Make decompressor reinitialization safe - #4941

Merged
terrelln merged 1 commit into
meta:devfrom
terrelln:2026-11-12-seekable-init
Nov 13, 2026
Merged

terrelln merged 1 commit into
meta:devfrom
terrelln:2026-11-12-seekable-init

Conversation

@terrelln

Copy link
Copy Markdown
Contributor

Reinitialization overwrote the previous seek-table allocation. Read failures while loading a new table could also leak it, and failed reinitialization could leave old decoder state paired with the new source.

Release the previous table and reset decoder state before initialization, free partially loaded tables on I/O errors, and reject decompression until initialization succeeds. Document the reset contract and add regression tests for reuse, failure, and recovery across all input APIs.

@meta-cla meta-cla Bot added the CLA Signed label Nov 12, 2026
@terrelln
terrelln force-pushed the 2026-11-12-seekable-init branch from 93dab90 to 9a37c21 Compare November 12, 2026 20:41
@terrelln
terrelln force-pushed the 2026-11-12-seekable-init branch 2 times, most recently from db8c162 to c6f4a5a Compare November 13, 2026 16:43
Reinitialization overwrote the previous seek-table allocation. Read failures while loading a new table could also leak it, and failed reinitialization could leave old decoder state paired with the new source.

Release the previous table and reset decoder state before initialization, free partially loaded tables on I/O errors, and reject decompression until initialization succeeds. Document the reset contract and add regression tests for reuse, failure, and recovery across all input APIs.
@terrelln
terrelln force-pushed the 2026-11-12-seekable-init branch from c6f4a5a to 2307c43 Compare November 13, 2026 16:47
@terrelln
terrelln merged commit bcd0995 into meta:dev Nov 13, 2026
109 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants