Skip to content

fix(tiff): fix heap overflow unpacking sub-8-bit contig CMYK samples#5296

Merged
lgritz merged 1 commit into
AcademySoftwareFoundation:mainfrom
lgritz:lg-tiff1bitcmyk
Jul 4, 2026
Merged

fix(tiff): fix heap overflow unpacking sub-8-bit contig CMYK samples#5296
lgritz merged 1 commit into
AcademySoftwareFoundation:mainfrom
lgritz:lg-tiff1bitcmyk

Conversation

@lgritz

@lgritz lgritz commented Jul 4, 2026

Copy link
Copy Markdown
Collaborator

We had missed a case where bit_convert needed outputs to go to the scratch buffer: PHOTOMETRIC_SEPARATED, but not requesting raw color. (Because the real number of channels differ from what we are presenting to the caller.)

Assisted-by: Claude Code / Sonnet 5

We had missed a case where bit_convert needed outputs to go to the
scratch buffer: PHOTOMETRIC_SEPARATED, but not requesting raw
color. (Because the real number of channels differ from what we are
presenting to the caller.)

Assisted-by: Claude Code / Sonnet 5

Signed-off-by: Larry Gritz <lg@larrygritz.com>

@jessey-git jessey-git left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks ok to me. The m_photometric == PHOTOMETRIC_SEPARATED && !m_raw_color conditional is used in several other places already.

@lgritz lgritz merged commit 6e9b86e into AcademySoftwareFoundation:main Jul 4, 2026
28 checks passed
@lgritz lgritz deleted the lg-tiff1bitcmyk branch July 5, 2026 01:12
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.

2 participants