Skip to content

Conversation

@devnexen
Copy link
Member

@devnexen devnexen commented Nov 2, 2025

  • forgotten remaining libzip < 1.0.0 code path.
  • earlier return on invalid inputs from some ZipArchive methods.

- forgotten remaining libzip < 1.0.0 code path.
- earlier return on invalid inputs from some ZipArchive methods.
TODO: fix mem leaks on encryption methods.
@devnexen devnexen marked this pull request as ready for review November 2, 2025 22:49
Comment on lines 2609 to 2611
if (index < 0) {
RETURN_FALSE;
}
Copy link
Member

Choose a reason for hiding this comment

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

I guess it might make sense to make those sorts of conditions a warning/value error in the future?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes I kept "api compatible" for now on purpose.

Comment on lines 3019 to 3022
if (method < 0) {
RETURN_FALSE;
}
RETVAL_BOOL(zip_compression_method_supported((zip_int32_t)method, enc));
Copy link
Member

Choose a reason for hiding this comment

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

Isn't this a problem if method is larger than a 32bit int but still positive on x64?

Copy link
Member Author

Choose a reason for hiding this comment

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

good point

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