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

Port patch from GHSA-mc3g-88wq-6f4x #36

Merged
merged 1 commit into from
Mar 7, 2022

Conversation

QuietMisdreavus
Copy link

Resolves rdar://89864410

This PR ports the patch from GHSA-mc3g-88wq-6f4x into the swift-cmark/gfm branch.

* added explicit check for UINT16_MAX boundary on row->n_columns

* added additional checks for row_from_string NULL returns to prevent NULL
dereferences on error cases

* added additional check to ensure n_columns between marker and header rows
always match prior to any alignment processing

* allocate alignment array based on marker rows rather than header rows

* prevent memory leak on dangling node when encountering row_from_string
error in try_opening_table_row

* add explicit integer overflow error marker to not overload offset semantics
in row_from_string with other implied error conditions
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