aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Editor.cxx
diff options
context:
space:
mode:
authorMitchell Foral <unknown>2022-12-01 17:27:09 +1100
committerMitchell Foral <unknown>2022-12-01 17:27:09 +1100
commit9a400bd33f0cb4f322de4208bb7159673a399521 (patch)
tree907794431dd3dc69f6eafc3da05eb0f60ccc5096 /src/Editor.cxx
parentb80ca55f14fc7e0aa582a1b0b2117faf23ec29be (diff)
downloadscintilla-mirror-9a400bd33f0cb4f322de4208bb7159673a399521.tar.gz
Change release compilation optimization option to favour speed over space.
-O2 for MSVC and -O3 for gcc and clang. Change code in Editor.cxx to avoid a warning that occurs with gcc -O3.
Diffstat (limited to 'src/Editor.cxx')
-rw-r--r--src/Editor.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index 1fb6d960d..72a8a4bd8 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -5872,7 +5872,7 @@ void Editor::StyleSetMessage(Message iMessage, uptr_t wParam, sptr_t lParam) {
if (!(classified & UTF8MaskInvalid)) {
// valid UTF-8
int len = classified & UTF8MaskWidth;
- while (len--)
+ for (int i=0; i<len && i<4; i++)
*rep++ = *utf8++;
}
*rep = 0;