From 7be3b5b8bac080a8762279531bbe758b3675cc38 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Fri, 26 May 2017 10:31:17 +0100 Subject: coverity#1409898 Dereference before null check Change-Id: I44b5ab0c66b4050c2ee47684af7526e2543945ca --- sc/source/core/tool/compiler.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sc') diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index 78d4f37afa35..a83e13f33a7a 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -1774,8 +1774,8 @@ ScCompiler::ScCompiler( ScDocument* pDocument, const ScAddress& rPos, ScTokenArr mbRewind( false ) { SetGrammar( ((eGrammar == formula::FormulaGrammar::GRAM_UNSPECIFIED) ? - (pDocument ? pDocument->GetGrammar() : formula::FormulaGrammar::GRAM_DEFAULT) : - eGrammar)); + pDocument->GetGrammar() : + eGrammar) ); nMaxTab = pDoc->GetTableCount() - 1; } -- cgit