diff options
Diffstat (limited to 'src/Document.cxx')
-rw-r--r-- | src/Document.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Document.cxx b/src/Document.cxx index 222a8bc31..2852e1097 100644 --- a/src/Document.cxx +++ b/src/Document.cxx @@ -608,7 +608,7 @@ bool Document::InGoodUTF8(Sci::Position pos, Sci::Position &start, Sci::Position // pos too far from lead return false; unsigned char charBytes[UTF8MaxBytes] = {leadByte,0,0,0}; - for (Sci::Position b=1; b<widthCharBytes && ((start+b) < Length()); b++) + for (Sci::Position b=1; b<widthCharBytes && ((start+b) < cb.Length()); b++) charBytes[b] = cb.CharAt(start+b); const int utf8status = UTF8Classify(charBytes, widthCharBytes); if (utf8status & UTF8MaskInvalid) |