diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2022-01-10 23:51:52 +0200 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2022-01-10 23:51:52 +0200 |
commit | 469ce7f7f6828aa8ed8d45fdff82cb33c1ec655d (patch) | |
tree | 6ec74d5dbe9c278663a99212cddf808e87d4e6c6 /indra/llui/lltextbase.cpp | |
parent | 83b4ea59fc8793ccbfb6b40ffff111de14ebd4d3 (diff) | |
parent | ee2d618706a8803372b92dbe47a165c70be6cef9 (diff) |
Merge branch 'DRTVWR-530-maint' into DRTVWR-553-maint-mix-JK
# Conflicts:
# indra/newview/app_settings/key_bindings.xml
# indra/newview/llappviewer.cpp
# indra/newview/llkeyconflict.cpp
Diffstat (limited to 'indra/llui/lltextbase.cpp')
-rw-r--r-- | indra/llui/lltextbase.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp index 05788f1b6c..0532750dce 100644 --- a/indra/llui/lltextbase.cpp +++ b/indra/llui/lltextbase.cpp @@ -1564,11 +1564,14 @@ void LLTextBase::reflow() { // find first element whose end comes after start_index line_list_t::iterator iter = std::upper_bound(mLineInfoList.begin(), mLineInfoList.end(), start_index, line_end_compare()); - line_start_index = iter->mDocIndexStart; - line_count = iter->mLineNum; - cur_top = iter->mRect.mTop; - getSegmentAndOffset(iter->mDocIndexStart, &seg_iter, &seg_offset); - mLineInfoList.erase(iter, mLineInfoList.end()); + if (iter != mLineInfoList.end()) + { + line_start_index = iter->mDocIndexStart; + line_count = iter->mLineNum; + cur_top = iter->mRect.mTop; + getSegmentAndOffset(iter->mDocIndexStart, &seg_iter, &seg_offset); + mLineInfoList.erase(iter, mLineInfoList.end()); + } } S32 line_height = 0; |