diff options
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/tool/compiler.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index 628465e0d085..cde3c16f4f4e 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -4325,7 +4325,8 @@ bool ScCompiler::NextNewToken( bool bInArray ) * handled by IsPredetectedReference(), this case here remains for * manual/API input. */ OUString aBad( aFormula.copy( nSrcPos-1 ) ); - eLastOp = pArr->AddBad( aBad )->GetOpCode(); + const FormulaToken* pBadToken = pArr->AddBad(aBad); + eLastOp = pBadToken ? pBadToken->GetOpCode() : ocNone; return false; } |