[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - sc/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Tue Apr 6 10:14:31 UTC 2021
sc/source/core/tool/compiler.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit cc7cdddac7b8e2317d300120cc5b359394a9d310
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Apr 2 14:28:37 2021 +0100
Commit: Xisco Fauli <xiscofauli at libreoffice.org>
CommitDate: Tue Apr 6 12:13:41 2021 +0200
ofz: Segv on unknown address
Change-Id: I6c69375a89781fc0b87230203335c861efb562f9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113481
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index eb8706596910..85ceb6a0d8f3 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -2643,7 +2643,14 @@ Label_MaskStateMachine:
if (eState != ssSkipReference)
{
*pSym++ = c;
- *pSym++ = *pSrc++;
+
+ if( pSym == &cSymbol[ MAXSTRLEN ] )
+ {
+ SetError( FormulaError::StringOverflow);
+ eState = ssStop;
+ }
+ else
+ *pSym++ = *pSrc++;
}
bAddToSymbol = false;
}
More information about the Libreoffice-commits
mailing list