Skip to content

fix unininitialized access in tdefl_record_literal#351

Open
vprevosto wants to merge 1 commit into
richgel999:masterfrom
vprevosto:master
Open

fix unininitialized access in tdefl_record_literal#351
vprevosto wants to merge 1 commit into
richgel999:masterfrom
vprevosto:master

Conversation

@vprevosto

Copy link
Copy Markdown

This is a follow-up from #189 and was also found while analyzing the code with Frama-C/Eva abstract interpreter. Actually, in tdefl_record_literal, d->m_pLZ_flags can point to the successive elements of d->m_lz_code_buf, and the PR mentioned above only initializes the first one. The proposed patch is to initialize each element to 0 as soon as we increment d->m_pLZ_flags.

An alternative solution would of course consist in memseting the entire array to 0 in tdefl_init instead of initializing only the first element.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant