Skip to content
New issue

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

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

Already on GitHub? # to your account

Don't treat \0 in description as literal null #2647

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

matt-phylum
Copy link

I think in the Gem description you meant to write \0 as human-readable text instead of a literal null byte. Heredoc strings interpret escapes unless you put single quotes like this. You can see it happening in the JSON version here where it says \u0000 instead: https://github.com/CocoaPods/Specs/blob/98a5cfac82ecccd406eeff0d549c8eccadf1b699/Specs/2/e/c/RxSwift/6.8.0/RxSwift.podspec.json#L5

https://docs.ruby-lang.org/en/master/syntax/literals_rdoc.html#label-Here+Document+Literals

@freak4pc
Copy link
Member

Hey, thanks, I'm not entirely understanding this fix. I've never seen a podspec that has the single-quote in the multiline literal like this. Could you elaborate?

@matt-phylum
Copy link
Author

I hadn't seen it before either. The linked documentation on heredocs says that interpolation and escape sequences can be disabled by using <<-'EXPECTED'. Alternatively, it'd probably work to write \\0 instead of \0, but then the description in the podspec file would look different from the rendered description.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants