Skip to content

Fix LengthEncodedInt returning the length of 1 for an empty slice #609

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

Merged
merged 3 commits into from
Aug 10, 2021

Conversation

viciious
Copy link
Contributor

Fixes #607

@lance6716
Copy link
Collaborator

hi, can you add some tests to verify this fix is valid?

@viciious
Copy link
Contributor Author

viciious commented Aug 10, 2021

Unfortunately I've no idea what the underlying cause of the issue is - we've only hit in production environment. For all I know, this change makes sense and does fix the panic.

@viciious
Copy link
Contributor Author

viciious commented Aug 10, 2021

Added a small unit test for this particular corner case in LengthEncodedInt

@atercattus atercattus merged commit 5399994 into go-mysql-org:master Aug 10, 2021
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.

Panic in LengthEncodedString
3 participants