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

Don't accept invalid characters #141

Closed
wants to merge 1 commit into from
Closed

Conversation

dchest
Copy link
Contributor

@dchest dchest commented Mar 30, 2016

Contructor from string accepted characters out of base range.
Fix by throwing exception when such character appears in the string.

PS Spent the whole day trying to figure out why my code didn't work only to discover that I forgot to add 16 as base for constructor (similar to the test in this commit) 😅

@fanatid
Copy link
Collaborator

fanatid commented Mar 30, 2016

Related: #90 #91

Contructor from string accepted characters out of base range.
Fix by throwing exception when such character appears in the string.
@dchest
Copy link
Contributor Author

dchest commented Mar 30, 2016

@fanatid this one will just make sure that decoded number is less than base, but won't reject other characters, e.g. I think : and ;, etc. (they are between numbers and letters in ASCII) will be accepted for base 16.

@fanatid
Copy link
Collaborator

fanatid commented Nov 7, 2016

semver-major btw

@indutny
Copy link
Owner

indutny commented Nov 29, 2017

Landed in 9827640, thank you!

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.

3 participants