diff options
author | Neil <nyamatongwe@gmail.com> | 2014-07-22 17:49:01 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2014-07-22 17:49:01 +1000 |
commit | 1b291b5c744ce17911d4f0af923b6f230192f6dd (patch) | |
tree | ccd431bfd312c9cfa2c012f77ed84ae1d4adbe09 /gtk | |
parent | 934368163fc7a096cb241d0d0f0ad26d66546d62 (diff) | |
download | scintilla-mirror-1b291b5c744ce17911d4f0af923b6f230192f6dd.tar.gz |
Make a little safer when there is text that is invalid in the encoding.
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/PlatGTK.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx index 88edfdec5..ac90dee2a 100644 --- a/gtk/PlatGTK.cxx +++ b/gtk/PlatGTK.cxx @@ -1088,6 +1088,10 @@ void SurfaceImpl::MeasureWidths(Font &font_, const char *s, int len, XYPOSITION } clusterStart = clusterEnd; } + while (i < lenPositions) { + // If something failed, fill in rest of the positions + positions[i++] = clusterStart; + } PLATFORM_ASSERT(i == lenPositions); } } |