Fixed range error with CR line endings

This commit is contained in:
Hackerpilot 2013-09-12 14:17:43 -07:00
parent 0f37f6692d
commit 68839deadc
1 changed files with 10 additions and 7 deletions

View File

@ -1707,6 +1707,8 @@ L_advance:
src.popFront(); src.popFront();
foundNewline = true; foundNewline = true;
} }
if (!src.empty)
{
if (src.front == '\n') if (src.front == '\n')
{ {
src.popFront(); src.popFront();
@ -1716,6 +1718,7 @@ L_advance:
{ {
src.popFront(); src.popFront();
} }
}
if (foundNewline) if (foundNewline)
{ {
++lineNumber; ++lineNumber;