diff options
author | Erik Kundiman <erik@megapahit.org> | 2025-03-29 05:54:13 +0800 |
---|---|---|
committer | Erik Kundiman <erik@megapahit.org> | 2025-03-29 05:54:13 +0800 |
commit | f6f22cf804c3bb0192c3215c05a89e78288c4d7c (patch) | |
tree | b5ce9d70574bfb38600fe7b0421e9014fd82213e /indra/llui/lltexteditor.cpp | |
parent | 1c5777bd52bc581841d832b52572370395f86ff7 (diff) | |
parent | 4e80ec7e962dde43c8d7379f0167a242704336ad (diff) |
Merge tag 'Second_Life_Release#4e80ec7e-2025.03' into 2025.03
Diffstat (limited to 'indra/llui/lltexteditor.cpp')
-rw-r--r-- | indra/llui/lltexteditor.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp index 3537c764b9..77a4976f6b 100644 --- a/indra/llui/lltexteditor.cpp +++ b/indra/llui/lltexteditor.cpp @@ -209,8 +209,15 @@ public: } virtual bool execute( LLTextBase* editor, S32* delta ) { - mWString = editor->getWText().substr(getPosition(), mLen); - *delta = remove(editor, getPosition(), mLen ); + try + { + mWString = editor->getWText().substr(getPosition(), mLen); + *delta = remove(editor, getPosition(), mLen); + } + catch (std::out_of_range&) + { + return false; + } return (*delta != 0); } virtual S32 undo( LLTextBase* editor ) |