Skip to content

Merge line endings parsing fix - #144

Merged
da4089 merged 3 commits into
masterfrom
branch-0.9
Aug 12, 2026
Merged

Merge line endings parsing fix#144
da4089 merged 3 commits into
masterfrom
branch-0.9

Conversation

@da4089

@da4089 da4089 commented Aug 12, 2026

Copy link
Copy Markdown

No description provided.

da4089 and others added 3 commits August 11, 2026 23:20
In some cases, the vobject text supplied does not have a line
terminator on the final line of the string/file.  This was handled
using the regex "$" syntax, but that meant every line was reporting
an extra line number consumed, because "$" matches either the end
of the string, or immediately before a final CR/LF.

So, logical lines still match either a CRLF, CR, LF, or "$", but
when removing folded lines, there's now an explicit check for a
training terminator, and one is added if it's missing.  That ensures
every line increments the counter by at least one, and the returned
line numbers are now correct for both folded and unfolded lines.
…-getlogicallines

Fixes #142 incorrect line numbers in getlogicallines
@da4089
da4089 merged commit 6d3a54e into master Aug 12, 2026
6 checks passed
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.

1 participant