Skip to content

Conversation

tikue
Copy link
Collaborator

@tikue tikue commented Mar 8, 2017

0 is a sentinel value used to make all enums refutable. This is a hack around issues in maros
where you're unknowingly treating irrefutable patterns as refutable, which is unfortunately
a hard error.

The server panics if it ever encountered the 0-variant, which before this patch was possible. Now,
it's not possible, because 0-variants are now not able to be deserialized.

0 is a sentinel value used to make all enums refutable. This is a hack around issues in maros
where you're unknowingly treating irrefutable patterns as refutable, which is unfortunately
a hard error.

The server panics if it ever encountered the 0-variant, which before this patch was possible. Now,
it's not possible, because 0-variants are now not able to be deserialized.
@tikue tikue self-assigned this Mar 8, 2017
@tikue tikue requested a review from shaladdle March 8, 2017 05:12
@tikue tikue merged commit 40faf25 into google:master Mar 23, 2017
@tikue tikue deleted the vuln branch July 30, 2019 03:54
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.

2 participants