diff options
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/ui/app/scmod.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/vba/vbarange.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/view/tabvwsh4.cxx | 1 |
3 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx index 09c7bbd63027..381c27501d07 100644 --- a/sc/source/ui/app/scmod.cxx +++ b/sc/source/ui/app/scmod.cxx @@ -1050,7 +1050,8 @@ void ScModule::ModifyOptions( const SfxItemSet& rOptSet ) aNewViewOpt.SetGridOptions( aNewGridOpt ); rViewData.SetOptions( aNewViewOpt ); rViewData.GetDocument()->SetViewOptions( aNewViewOpt ); - pDocSh->SetDocumentModified(); + if (pDocSh) + pDocSh->SetDocumentModified(); bRepaint = true; } } diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx index f1500352d4fd..747dbf4b24cd 100644 --- a/sc/source/ui/vba/vbarange.cxx +++ b/sc/source/ui/vba/vbarange.cxx @@ -1777,6 +1777,7 @@ ScVbaRange::HasFormula() { uno::Reference<uno::XInterface> xRanges( pThisRanges->queryFormulaCells( sheet::FormulaResult::ERROR | sheet::FormulaResult::VALUE | sheet::FormulaResult::STRING ), uno::UNO_QUERY_THROW ); ScCellRangesBase* pFormulaRanges = dynamic_cast< ScCellRangesBase * > ( xRanges.get() ); + assert(pFormulaRanges); // check if there are no formula cell, return false if ( pFormulaRanges->GetRangeList().empty() ) return uno::makeAny(false); diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx index 18bf7326a1b4..0c40536f534b 100644 --- a/sc/source/ui/view/tabvwsh4.cxx +++ b/sc/source/ui/view/tabvwsh4.cxx @@ -1727,6 +1727,7 @@ ScTabViewShell::ScTabViewShell( SfxViewFrame* pViewFrame, if (pViewShell2 && pViewShell2 == this) { ScTabViewShell* pTabViewShell = dynamic_cast<ScTabViewShell*>(pViewShell); + assert(pTabViewShell); ScInputHandler* pInputHdl = pTabViewShell->GetInputHandler(); if (pInputHdl && pInputHdl->IsFormulaMode()) { |