Skip to content

Fix compression components#3684

Merged
rhc54 merged 1 commit intoopenpmix:masterfrom
rhc54:topic/cmpress
Sep 30, 2025
Merged

Fix compression components#3684
rhc54 merged 1 commit intoopenpmix:masterfrom
rhc54:topic/cmpress

Conversation

@rhc54
Copy link
Contributor

@rhc54 rhc54 commented Sep 30, 2025

We were mistakenly comparing the size of the working buffer to the input size and not compressing if the working buffer was larger. However, zlib always uses a larger working buffer, and so this prevented us from actually compressing.

Compare the size of the resulting compressed data to the input data and don't use the compressed block if it isn't smaller - it can happen, though probably rare.

We were mistakenly comparing the size of the working buffer to
the input size and not compressing if the working buffer was
larger. However, zlib _always_ uses a larger working buffer,
and so this prevented us from actually compressing.

Compare the size of the resulting compressed data to the
input data and don't use the compressed block if it isn't
smaller - it can happen, though probably rare.

Signed-off-by: Ralph Castain <rhc@pmix.org>
@rhc54 rhc54 merged commit 0fe0c59 into openpmix:master Sep 30, 2025
26 checks passed
@rhc54 rhc54 deleted the topic/cmpress branch September 30, 2025 23:50
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