Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zip: avoid runtime modifications of deflate signature #5376

Merged
merged 1 commit into from Jan 2, 2018
Merged

Zip: avoid runtime modifications of deflate signature #5376

merged 1 commit into from Jan 2, 2018

Conversation

luislavena
Copy link
Contributor

Freeze DEFLATE_END_SIGNATURE slice contents to avoid possible runtime alterations.

The constant is referenced at runtime when writing content to IO, so this change ensures the value written is consistent.

Thank you.
❤️ ❤️ ❤️

Freeze `DEFLATE_END_SIGNATURE` slice contents to avoid possible runtime
alterations.

The constant is referenced at runtime when writing content to IO, so this
change ensures the value written is consistent.
@RX14
Copy link
Contributor

RX14 commented Dec 11, 2017

I'm interested: did you just spot this or did this modification actually happen somewhere?

@luislavena
Copy link
Contributor Author

luislavena commented Dec 12, 2017

Just spotted this while working on some Zip-related code. Nothing to worry about. 😁

Cheers.

@RX14 RX14 added this to the Next milestone Jan 2, 2018
@RX14 RX14 merged commit 1293308 into crystal-lang:master Jan 2, 2018
@luislavena luislavena deleted the freeze-deflate-signature branch January 2, 2018 22:15
lukeasrodgers pushed a commit to lukeasrodgers/crystal that referenced this pull request Jan 7, 2018
)

Freeze `DEFLATE_END_SIGNATURE` slice contents to avoid possible runtime
alterations.

The constant is referenced at runtime when writing content to IO, so this
change ensures the value written is consistent.
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.

None yet

3 participants