[ooo-build-commit] .: sw/source

Noel Power noelp at kemper.freedesktop.org
Mon Oct 4 06:49:14 PDT 2010


 sw/source/ui/uiview/viewprt.cxx |    9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

New commits:
commit 8b072fd99db5f6ca0f0b3adf9acfebddd3c47854
Author: Harri Pitkänen <hatapitk at iki.fi>
Date:   Mon Oct 4 14:48:25 2010 +0100

    silence cppcheck "possible null pointer dereference"

diff --git a/sw/source/ui/uiview/viewprt.cxx b/sw/source/ui/uiview/viewprt.cxx
index 88ad189..0f7aabd 100644
--- a/sw/source/ui/uiview/viewprt.cxx
+++ b/sw/source/ui/uiview/viewprt.cxx
@@ -321,14 +321,9 @@ void __EXPORT SwView::ExecutePrint(SfxRequest& rReq)
 SfxTabPage* CreatePrintOptionsPage( Window *pParent,
                                 const SfxItemSet &rOptions, BOOL bPreview )
 {
-    SfxTabPage* pPage = NULL;
     SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create();
-    if ( pFact )
-    {
-        ::CreateTabPage fnCreatePage = pFact->GetTabPageCreatorFunc( TP_OPTPRINT_PAGE );
-        if ( fnCreatePage )
-            pPage = (*fnCreatePage)( pParent, rOptions );
-    }
+    ::CreateTabPage fnCreatePage = pFact->GetTabPageCreatorFunc( TP_OPTPRINT_PAGE );
+    SfxTabPage* pPage = (*fnCreatePage)( pParent, rOptions );
     SfxAllItemSet aSet(*(rOptions.GetPool()));
     aSet.Put (SfxBoolItem(SID_PREVIEWFLAG_TYPE, bPreview));
     aSet.Put (SfxBoolItem(SID_FAX_LIST, sal_True));


More information about the ooo-build-commit mailing list