diff options
-rw-r--r-- | dbaccess/qa/unit/embeddeddb_performancetest.cxx | 11 | ||||
-rw-r--r-- | reportdesign/source/ui/report/ViewsWindow.cxx | 17 | ||||
-rw-r--r-- | sc/source/filter/xcl97/XclExpChangeTrack.cxx | 3 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8scan.cxx | 5 | ||||
-rw-r--r-- | sw/source/ui/dialog/swdlgfact.cxx | 4 |
5 files changed, 12 insertions, 28 deletions
diff --git a/dbaccess/qa/unit/embeddeddb_performancetest.cxx b/dbaccess/qa/unit/embeddeddb_performancetest.cxx index 1eebc2206f22..a639d72e9b2c 100644 --- a/dbaccess/qa/unit/embeddeddb_performancetest.cxx +++ b/dbaccess/qa/unit/embeddeddb_performancetest.cxx @@ -129,16 +129,7 @@ SvFileStream* EmbeddedDBPerformanceTest::getWordListStream() { OUString wlPath; createFileURL("wordlist", wlPath); - - SvFileStream *pFile(new SvFileStream(wlPath, StreamMode::READ)); - - if (!pFile) - { - fprintf(stderr, "Please ensure the wordlist is present\n"); - CPPUNIT_ASSERT(false); - } - - return pFile; + return new SvFileStream(wlPath, StreamMode::READ); } void EmbeddedDBPerformanceTest::printTimes( diff --git a/reportdesign/source/ui/report/ViewsWindow.cxx b/reportdesign/source/ui/report/ViewsWindow.cxx index c849571e2c10..730b37258717 100644 --- a/reportdesign/source/ui/report/ViewsWindow.cxx +++ b/reportdesign/source/ui/report/ViewsWindow.cxx @@ -1011,18 +1011,15 @@ void OViewsWindow::BegDragObj_createInvisibleObjectAtPosition(const Rectangle& _ if ( &rView != &_rSection ) { SdrObject *pNewObj = new SdrUnoObj(OUString("com.sun.star.form.component.FixedText")); - if (pNewObj) - { - pNewObj->SetLogicRect(_aRect); + pNewObj->SetLogicRect(_aRect); - pNewObj->Move(Size(0, aNewPos.Y())); - bool bChanged = rView.GetModel()->IsChanged(); - rReportSection.getPage()->InsertObject(pNewObj); - rView.GetModel()->SetChanged(bChanged); - m_aBegDragTempList.push_back(pNewObj); + pNewObj->Move(Size(0, aNewPos.Y())); + bool bChanged = rView.GetModel()->IsChanged(); + rReportSection.getPage()->InsertObject(pNewObj); + rView.GetModel()->SetChanged(bChanged); + m_aBegDragTempList.push_back(pNewObj); - rView.MarkObj( pNewObj, rView.GetSdrPageView() ); - } + rView.MarkObj( pNewObj, rView.GetSdrPageView() ); } const long nSectionHeight = rReportSection.PixelToLogic(rReportSection.GetOutputSizePixel()).Height(); aNewPos.Y() -= nSectionHeight; diff --git a/sc/source/filter/xcl97/XclExpChangeTrack.cxx b/sc/source/filter/xcl97/XclExpChangeTrack.cxx index 2989f20b5af9..e90ebfa74e46 100644 --- a/sc/source/filter/xcl97/XclExpChangeTrack.cxx +++ b/sc/source/filter/xcl97/XclExpChangeTrack.cxx @@ -1546,9 +1546,6 @@ ScChangeTrack* XclExpChangeTrack::CreateTempChangeTrack() // create empty document pTempDoc = new ScDocument; - OSL_ENSURE( pTempDoc, "XclExpChangeTrack::CreateTempChangeTrack - no temp document" ); - if( !pTempDoc ) - return NULL; // adjust table count SCTAB nOrigCount = GetDoc().GetTableCount(); diff --git a/sw/source/filter/ww8/ww8scan.cxx b/sw/source/filter/ww8/ww8scan.cxx index 22d93f1e8aa1..8c4f8287708a 100644 --- a/sw/source/filter/ww8/ww8scan.cxx +++ b/sw/source/filter/ww8/ww8scan.cxx @@ -2884,9 +2884,10 @@ bool WW8PLCFx_Fc_FKP::NewFkp() pFkp = *aIter; pFkp->Reset(GetStartFc()); } - else if (0 != (pFkp = new WW8Fkp(GetFIBVersion(), pFKPStrm, pDataStrm, nPo, - pFkpSizeTab[ ePLCF ], ePLCF, GetStartFc()))) + else { + pFkp = new WW8Fkp(GetFIBVersion(), pFKPStrm, pDataStrm, nPo, + pFkpSizeTab[ ePLCF ], ePLCF, GetStartFc()); maFkpCache.push_back(pFkp); if (maFkpCache.size() > eMaxCache) diff --git a/sw/source/ui/dialog/swdlgfact.cxx b/sw/source/ui/dialog/swdlgfact.cxx index 8bc1190a50a6..a64cb0820089 100644 --- a/sw/source/ui/dialog/swdlgfact.cxx +++ b/sw/source/ui/dialog/swdlgfact.cxx @@ -987,9 +987,7 @@ AbstractInsFootNoteDlg* SwAbstractDialogFactory_Impl::CreateInsFootNoteDlg( VclAbstractDialog * SwAbstractDialogFactory_Impl::CreateTitlePageDlg ( vcl::Window *pParent ) { Dialog* pDlg = new SwTitlePageDlg( pParent ); - if ( pDlg ) - return new VclAbstractDialog_Impl( pDlg ); - return 0; + return new VclAbstractDialog_Impl( pDlg ); } VclAbstractDialog * SwAbstractDialogFactory_Impl::CreateVclSwViewDialog(SwView& rView) |