cui/source/tabpages/grfpage.cxx | 24 +++++++++++++----------- cui/source/tabpages/swpossizetabpage.cxx | 3 +-- sfx2/source/control/unoctitm.cxx | 2 +- svtools/source/contnr/svimpbox.cxx | 2 +- 4 files changed, 16 insertions(+), 15 deletions(-)
New commits: commit c3c1a8f373e73d8bfa3180a21ccae0e4fb1cd982 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Feb 10 20:55:35 2014 +0000 coverity#704611 Dereference after null check Change-Id: I7ce68773c85408d0dc3d46bac85bcbd0f5806ade diff --git a/cui/source/tabpages/swpossizetabpage.cxx b/cui/source/tabpages/swpossizetabpage.cxx index 43f0f4a..bacecec 100644 --- a/cui/source/tabpages/swpossizetabpage.cxx +++ b/cui/source/tabpages/swpossizetabpage.cxx @@ -1274,8 +1274,7 @@ IMPL_LINK( SvxSwPosSizeTabPage, PosHdl, ListBox *, pLB ) m_pVertByFT->Enable( bEnable ); } - if (pLB) // only if the hanlder has been called by a change of the controller - RangeModifyHdl( 0 ); + RangeModifyHdl( 0 ); short nRel = 0; if (pLB->GetSelectEntryCount()) commit 750105967d6add2670cff5847ea74da925a3e679 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Feb 10 20:53:03 2014 +0000 coverity#704610 Dereference after null check Change-Id: I1a08d643a695f1d22e339b8906588aca7d190578 diff --git a/cui/source/tabpages/grfpage.cxx b/cui/source/tabpages/grfpage.cxx index 065bee0..8d8ce6f 100644 --- a/cui/source/tabpages/grfpage.cxx +++ b/cui/source/tabpages/grfpage.cxx @@ -204,23 +204,25 @@ void SvxGrfCropPage::Reset( const SfxItemSet &rSet ) referer = it->GetValue(); } const Graphic* pGrf = ((SvxBrushItem*)pItem)->GetGraphic(referer); - if( pGrf ) { + if( pGrf ) + { aOrigSize = GetGrfOrigSize( *pGrf ); - if (pGrf->GetType() == GRAPHIC_BITMAP && aOrigSize.Width() && aOrigSize.Height()) { + if (pGrf->GetType() == GRAPHIC_BITMAP && aOrigSize.Width() && aOrigSize.Height()) + { Bitmap aBitmap = pGrf->GetBitmap(); aOrigPixelSize = aBitmap.GetSizePixel(); } - } - if( aOrigSize.Width() && aOrigSize.Height() ) - { - CalcMinMaxBorder(); - m_pExampleWN->SetGraphic( *pGrf ); - m_pExampleWN->SetFrameSize( aOrigSize ); + if( aOrigSize.Width() && aOrigSize.Height() ) + { + CalcMinMaxBorder(); + m_pExampleWN->SetGraphic( *pGrf ); + m_pExampleWN->SetFrameSize( aOrigSize ); - bFound = sal_True; - if( !((SvxBrushItem*)pItem)->GetGraphicLink().isEmpty() ) - aGraphicName = ((SvxBrushItem*)pItem)->GetGraphicLink(); + bFound = sal_True; + if( !((SvxBrushItem*)pItem)->GetGraphicLink().isEmpty() ) + aGraphicName = ((SvxBrushItem*)pItem)->GetGraphicLink(); + } } } commit c748d6115e6c9f2820701e410611b75c09156987 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Feb 10 20:51:29 2014 +0000 coverity#440991 Dereference after null check Change-Id: I3b911e4bc1e6c2eccf4b9655f12162936fc5a946 diff --git a/svtools/source/contnr/svimpbox.cxx b/svtools/source/contnr/svimpbox.cxx index 3618681..6ac1b35 100644 --- a/svtools/source/contnr/svimpbox.cxx +++ b/svtools/source/contnr/svimpbox.cxx @@ -2346,7 +2346,7 @@ bool SvImpLBox::KeyInput( const KeyEvent& rKEvt) nDelta--; } - if( nDelta ) + if( nDelta && pNewCursor ) { DBG_ASSERT(pNewCursor&&(sal_uLong)pNewCursor!=(sal_uLong)pCursor,"Cursor?"); aSelEng.CursorPosChanging( bShift, bMod1 ); commit 9e6dfbd2444be53e28d3ca5e8dc786a4099af413 Author: Caolán McNamara <caol...@redhat.com> Date: Mon Feb 10 20:49:48 2014 +0000 coverity#441011 Dereference after null check Change-Id: I8a3430440bdd8cc1561eb60863c2bda3df8eac6d diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 1fbcba9..413fa96 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -809,7 +809,7 @@ void SAL_CALL SfxDispatchController_Impl::addStatusListener(const ::com::sun::st ::com::sun::star::uno::Any aState; if ( !pDispatcher && pBindings ) pDispatcher = GetBindings().GetDispatcher_Impl(); - SfxItemState eState = pDispatcher->QueryState( GetId(), aState ); + SfxItemState eState = pDispatcher ? pDispatcher->QueryState( GetId(), aState ) : SFX_ITEM_DONTCARE; if ( eState == SFX_ITEM_DONTCARE ) {
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits