diff options
author | Eike Rathke <erack@redhat.com> | 2017-12-02 15:32:06 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2017-12-02 19:53:06 +0100 |
commit | fc672573ce37f7845cb3121b2203caeaf0199669 (patch) | |
tree | 119359697588b3e2f22f939124eb5a319c489079 | |
parent | afbd0960f0b8d8b27cc9582279367540cc8aad84 (diff) |
ofz#4484 another stab at mnRangeOpPosInSymbol
Commit cd0b749cc4b4f268d26639fb3c6cbf2128b2d7df still missed it by
one position behind string length.
Also move the check to end of i18n symbol parsing for all
constellations.
Change-Id: I7b5e1375fe711dcc3f659e558702de78893d25a5
Reviewed-on: https://gerrit.libreoffice.org/45717
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins <ci@libreoffice.org>
-rw-r--r-- | sc/source/core/tool/compiler.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index dce7841b80cd..8f74f42276a4 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -2672,9 +2672,9 @@ Label_MaskStateMachine: { SetError( FormulaError::StringOverflow ); nLen = MAXSTRLEN; - if (mnRangeOpPosInSymbol > nLen) - mnRangeOpPosInSymbol = -1; } + if (mnRangeOpPosInSymbol >= nLen) + mnRangeOpPosInSymbol = -1; lcl_UnicodeStrNCpy( cSymbol, aSymbol.getStr(), nLen ); pSym = &cSymbol[nLen]; } |