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

Fix extra line feeds in link title #826

Merged
merged 2 commits into from
Nov 24, 2024
Merged

Fix extra line feeds in link title #826

merged 2 commits into from
Nov 24, 2024

Conversation

snnz
Copy link
Contributor

@snnz snnz commented Nov 21, 2024

Extra line feeds appear in the parsed link titles containing Windows-style line breaks, because \n that is peeked after \r is not skipped.

@xoofx
Copy link
Owner

xoofx commented Nov 21, 2024

Thanks! Good catch, could you add a test?

@snnz
Copy link
Contributor Author

snnz commented Nov 21, 2024

I've added a test. In the current version, it fails with the message:
Expected string length 16 but was 17. Strings differ at index 9. Expected: "this\ris\r\na\ntitle" But was: "this\ris\r\n\na\ntitle"

@xoofx xoofx merged commit 49cf59b into xoofx:master Nov 24, 2024
1 check passed
@xoofx xoofx added the bug label Nov 24, 2024
@snnz snnz deleted the fix-extra-lfs branch November 24, 2024 16:55
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants