filter/source/msfilter/svdfppt.cxx | 29 ---------- framework/source/uiconfiguration/windowstateconfiguration.cxx | 2 lingucomponent/source/thesaurus/libnth/nthesimp.cxx | 3 - lotuswordpro/source/filter/lwpgrfobj.cxx | 2 oox/source/ole/olehelper.cxx | 2 scaddins/source/analysis/analysishelper.cxx | 2 svl/source/numbers/zformat.cxx | 1 sw/source/core/docnode/node.cxx | 1 sw/source/core/txtnode/ndtxt.cxx | 6 +- sw/source/core/uibase/index/toxmgr.cxx | 14 ---- sw/source/core/undo/rolbck.cxx | 2 sw/source/core/unocore/unodraw.cxx | 2 toolkit/source/awt/vclxwindow.cxx | 8 +- writerfilter/source/dmapper/DomainMapper_Impl.cxx | 2 14 files changed, 15 insertions(+), 61 deletions(-)
New commits: commit b88434d67bf0304e3077130763226ebe42093be5 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 12:12:37 2014 +0000 Resolves: rhbz#1077780 crash on loading .docx Change-Id: I92670b9c46a2c745ba47c6dcc1b4dd672942cf59 diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx index aa0896a..79c1847 100644 --- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx +++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx @@ -636,6 +636,8 @@ void lcl_MoveBorderPropertiesToFrame(uno::Sequence<beans::PropertyValue>& rFrame { try { + if (!xStartTextRange.is()) //rhbz#1077780 + return; uno::Reference<text::XTextCursor> xRangeCursor = xStartTextRange->getText()->createTextCursorByRange( xStartTextRange ); xRangeCursor->gotoRange( xEndTextRange, true ); commit dd139fa3e49991c06e08133d6f3afd62ce894052 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 11:18:09 2014 +0000 coverity#735446 Logically dead code Change-Id: I6615145e2529193cbe72f4e5d326832a5b8864d0 diff --git a/oox/source/ole/olehelper.cxx b/oox/source/ole/olehelper.cxx index fac3ec4..2d1bdd5 100644 --- a/oox/source/ole/olehelper.cxx +++ b/oox/source/ole/olehelper.cxx @@ -511,7 +511,7 @@ bool MSConvertOCXControls::importControlFromStream( ::oox::BinaryInputStream& rI bool bOneOfHtmlControls = false; if ( rStrmClassId.toAsciiUpperCase().equalsAscii( HTML_GUID_SELECT ) || rStrmClassId.toAsciiUpperCase().equalsAscii( HTML_GUID_TEXTBOX ) ) - bOneOfHtmlControls = false; + bOneOfHtmlControls = true; if ( bOneOfHtmlControls ) { commit 1cc0bdd037f75eb0294c81b31ac32509577b80e2 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:44:01 2014 +0000 coverity#735439 Logically dead code Change-Id: Id475c10effc81386a08337128be270f715daef52 diff --git a/lingucomponent/source/thesaurus/libnth/nthesimp.cxx b/lingucomponent/source/thesaurus/libnth/nthesimp.cxx index b0b9972..300d0f3 100644 --- a/lingucomponent/source/thesaurus/libnth/nthesimp.cxx +++ b/lingucomponent/source/thesaurus/libnth/nthesimp.cxx @@ -404,7 +404,6 @@ Sequence < Reference < ::com::sun::star::linguistic2::XMeaning > > SAL_CALL Thes { OUString sTerm(pe->psyns[i],strlen(pe->psyns[i]),eEnc ); sal_Int32 catpos = sTerm.indexOf('('); - sal_Int32 catpos2 = 0; OUString catst; OUString catst2; if (catpos > 2) @@ -427,8 +426,6 @@ Sequence < Reference < ::com::sun::star::linguistic2::XMeaning > > SAL_CALL Thes sTerm = seq[0]; } } - if (catpos2) - sTerm = catst2 + sTerm; sal_uInt16 ct1 = capitalType(sTerm, pCC); if (CAPTYPE_MIXED == ct1) commit 6137b5f72f5ec491ea6bd6631a65484fa24d2973 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:42:51 2014 +0000 coverity#735432 Logically dead code Change-Id: I6bbbe539d28aefcad04ccae48f2518e78f15b240 diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx index 089ae8a..d92da70 100644 --- a/filter/source/msfilter/svdfppt.cxx +++ b/filter/source/msfilter/svdfppt.cxx @@ -2851,35 +2851,6 @@ void SdrPowerPointImport::ImportPage( SdrPage* pRet, const PptSlidePersistEntry* aEscherObjListHd.SeekToEndOfRecord( rStCtrl ); } - /* There are a lot of Shapes which are dependent to - the current background color */ - if ( rSlidePersist.ePageKind == PPT_SLIDEPAGE ) - { - if ( !aProcessData.aBackgroundColoredObjects.empty() ) - { - if ( rSlidePersist.pBObj ) - { - const SfxPoolItem* pPoolItem = NULL; - const SfxItemSet& rObjectItemSet = rSlidePersist.pBObj->GetMergedItemSet(); - - //SfxItemState eState = rObjectItemSet.GetItemState( XATTR_FILLCOLOR, sal_False, &pPoolItem ); - if ( pPoolItem ) - { - SfxItemSet aNewSet(*rObjectItemSet.GetPool()); - aNewSet.Put(*pPoolItem); - aNewSet.Put(XFillStyleItem( XFILL_SOLID )); - - for ( - size_t i = 0, n = aProcessData.aBackgroundColoredObjects.size(); - i < n; - ++i - ) { - aProcessData.aBackgroundColoredObjects[ i ]->SetMergedItemSet(aNewSet); - } - } - } - } - } if ( rSlidePersist.pBObj ) { // #i99386# transfer the attributes from the temporary BackgroundObject commit da5ac820d7200e70569f14a0468115ce4dc402f1 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:35:19 2014 +0000 coverity#704376 Logically dead code Change-Id: I4ab6a73a0b24db2d07c33cd593b0898b87c90fd3 diff --git a/sw/source/core/uibase/index/toxmgr.cxx b/sw/source/core/uibase/index/toxmgr.cxx index c29bd7b..2b4964a 100644 --- a/sw/source/core/uibase/index/toxmgr.cxx +++ b/sw/source/core/uibase/index/toxmgr.cxx @@ -453,16 +453,11 @@ sal_Bool SwTOXMgr::UpdateOrInsertTOX(const SwTOXDescription& rDesc, if (pDoc->GetIDocumentUndoRedo().DoesUndo()) { - if (pNewTOX != NULL) - { - pDoc->GetIDocumentUndoRedo().DelAllUndoObj(); - } - + pDoc->GetIDocumentUndoRedo().DelAllUndoObj(); pDoc->GetIDocumentUndoRedo().StartUndo(UNDO_TOXCHANGE, NULL); } - if (pNewTOX != NULL) // => pTOX != NULL - pDoc->ChgTOX(*pTOX, *pNewTOX); + pDoc->ChgTOX(*pTOX, *pNewTOX); pTOX->DisableKeepExpression(); bRet = pSh->UpdateTableOf(*pTOX, pSet); @@ -471,11 +466,6 @@ sal_Bool SwTOXMgr::UpdateOrInsertTOX(const SwTOXDescription& rDesc, if (pDoc->GetIDocumentUndoRedo().DoesUndo()) { pDoc->GetIDocumentUndoRedo().EndUndo(UNDO_TOXCHANGE, NULL); - - if (pNewTOX == NULL) - { - pDoc->GetIDocumentUndoRedo().DelAllUndoObj(); - } } } commit a79afdaa11a1af26c9404441dcf27ef197e972b2 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:28:56 2014 +0000 coverity#736158 Dereference null return value Change-Id: Ia3afc3989d1c9a5d9c70b167186fd81a263550fb diff --git a/toolkit/source/awt/vclxwindow.cxx b/toolkit/source/awt/vclxwindow.cxx index 9b5ff6b..b472c89 100644 --- a/toolkit/source/awt/vclxwindow.cxx +++ b/toolkit/source/awt/vclxwindow.cxx @@ -2243,13 +2243,15 @@ void VCLXWindow::draw( sal_Int32 nX, sal_Int32 nY ) throw(::com::sun::star::uno: if ( isDesignMode() || mpImpl->isEnableVisible() ) { + OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( mpImpl->mxViewGraphics ); + if (!pDev) + pDev = pWindow->GetParent(); TabPage* pTabPage = dynamic_cast< TabPage* >( pWindow ); if ( pTabPage ) { Point aPos( nX, nY ); Size aSize = pWindow->GetSizePixel(); - OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( mpImpl->mxViewGraphics ); aPos = pDev->PixelToLogic( aPos ); aSize = pDev->PixelToLogic( aSize ); @@ -2257,12 +2259,8 @@ void VCLXWindow::draw( sal_Int32 nX, sal_Int32 nY ) throw(::com::sun::star::uno: return; } - OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( mpImpl->mxViewGraphics ); Point aPos( nX, nY ); - if ( !pDev ) - pDev = pWindow->GetParent(); - if ( pWindow->GetParent() && !pWindow->IsSystemWindow() && ( pWindow->GetParent() == pDev ) ) { // #i40647# don't draw here if this is a recursive call commit fcdae12f366cef3d204ee34ec7618f0c2e1d57ff Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:25:44 2014 +0000 coverity#736142 Dereference null return value Change-Id: I89e0ac7fe236edee43f4ce12789d1ad024d7eb08 diff --git a/lotuswordpro/source/filter/lwpgrfobj.cxx b/lotuswordpro/source/filter/lwpgrfobj.cxx index cdb5489..d24c9cb 100644 --- a/lotuswordpro/source/filter/lwpgrfobj.cxx +++ b/lotuswordpro/source/filter/lwpgrfobj.cxx @@ -278,7 +278,7 @@ void LwpGraphicObject::RegisterStyle() if (m_sServerContextFormat[1]=='l'&&m_sServerContextFormat[2]=='c'&&m_sServerContextFormat[3]=='h') { LwpVirtualLayout* pMyLayout = GetLayout(NULL); - if(pMyLayout->IsFrame()) + if (pMyLayout && pMyLayout->IsFrame()) { XFFrameStyle* pXFFrameStyle = new XFFrameStyle(); pXFFrameStyle->SetXPosType(enumXFFrameXPosFromLeft, enumXFFrameXRelFrame); commit d112c8e677e9c07fd0601c7efe41e3cca25d1b41 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:21:32 2014 +0000 coverity#704953 Dereference after null check Change-Id: I134feebf45ff83a78b1b9e691a2731990b8e3f21 diff --git a/sw/source/core/unocore/unodraw.cxx b/sw/source/core/unocore/unodraw.cxx index 101f998..bf91fd3 100644 --- a/sw/source/core/unocore/unodraw.cxx +++ b/sw/source/core/unocore/unodraw.cxx @@ -814,8 +814,8 @@ void SwXDrawPage::ungroup(const uno::Reference< drawing::XShapeGroup > & xShapeG FLY_AT_PARA/*int eAnchorId*/, true, false ); pDoc->GetIDocumentUndoRedo().EndUndo( UNDO_END, NULL ); + pPage->RemovePageView(); } - pPage->RemovePageView(); } } commit 3f731937454f47eec2d66ef8f61ef4bc097fb588 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:20:36 2014 +0000 coverity#704949 Dereference after null check Change-Id: I25fbecbe3dd0c6a9f25b7641ac93842dba66abb7 diff --git a/sw/source/core/undo/rolbck.cxx b/sw/source/core/undo/rolbck.cxx index 0dd4162..1ff07eb 100644 --- a/sw/source/core/undo/rolbck.cxx +++ b/sw/source/core/undo/rolbck.cxx @@ -1308,7 +1308,7 @@ void SwRegHistory::Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ) { m_pHistory->Add( pOld, pNew, m_nNodeIndex ); } - else if ( RES_ATTRSET_CHG == pNew->Which() ) + else if (pOld && RES_ATTRSET_CHG == pNew->Which()) { SwHistoryHint* pNewHstr; const SfxItemSet& rSet = commit 145d278b2297a7ae2a1729c8bb9cb31b4aef3abf Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:19:14 2014 +0000 coverity#704947 Dereference after null check Change-Id: Iff2a146e217bb6953525ee86ddc84d8c134ab8aa diff --git a/sw/source/core/docnode/node.cxx b/sw/source/core/docnode/node.cxx index f6cd10b..c7d8b14 100644 --- a/sw/source/core/docnode/node.cxx +++ b/sw/source/core/docnode/node.cxx @@ -928,6 +928,7 @@ void SwCntntNode::Modify( const SfxPoolItem* pOldValue, const SfxPoolItem* pNewV switch( nWhich ) { case RES_OBJECTDYING : + if (pNewValue) { SwFmt * pFmt = (SwFmt *) ((SwPtrMsgPoolItem *)pNewValue)->pObject; commit 5fa0e2a400704548e85bd05731145303c2a9b694 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:17:49 2014 +0000 coverity#704946 Dereference after null check Change-Id: I816b4305261e6a9971c7cbc838381982972652c2 diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx index 3d3afcb..4812b4d 100644 --- a/sw/source/core/txtnode/ndtxt.cxx +++ b/sw/source/core/txtnode/ndtxt.cxx @@ -1125,7 +1125,7 @@ void SwTxtNode::_ChgTxtCollUpdateNum( const SwTxtFmtColl *pOldColl, pDoc->GetFtnIdxs().UpdateFtn( aTmpIndex); } - if( RES_CONDTXTFMTCOLL == pNewColl->Which() ) + if( pNewColl && RES_CONDTXTFMTCOLL == pNewColl->Which() ) { // Erfrage die akt. Condition des TextNodes: ChkCondColl(); commit bcbef3acbf80cabcd78eb4c6320b6a116a70f5ff Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:17:03 2014 +0000 coverity#704945 Dereference after null check Change-Id: I23606421cdae293d9021cafcc22c4a326c50d49b diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx index b7183c0..3d3afcb 100644 --- a/sw/source/core/txtnode/ndtxt.cxx +++ b/sw/source/core/txtnode/ndtxt.cxx @@ -1116,7 +1116,7 @@ void SwTxtNode::_ChgTxtCollUpdateNum( const SwTxtFmtColl *pOldColl, SwNodes& rNds = GetNodes(); // Update beim Level 0 noch die Fussnoten !! - if( ( !nNewLevel || !nOldLevel) && !pDoc->GetFtnIdxs().empty() && + if( ( !nNewLevel || !nOldLevel) && pDoc && !pDoc->GetFtnIdxs().empty() && FTNNUM_CHAPTER == pDoc->GetFtnInfo().eNum && rNds.IsDocNodes() ) { commit f02c2cbb28d7748aab9702218e901c2775d4d3a2 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:15:45 2014 +0000 coverity#704938 Dereference after null check Change-Id: I4108ee2cf86f0cf080a7590a0b2667071418673c diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx index 017c4b6..b7183c0 100644 --- a/sw/source/core/txtnode/ndtxt.cxx +++ b/sw/source/core/txtnode/ndtxt.cxx @@ -1403,7 +1403,7 @@ void lcl_CopyHint( SwCharFmt* pFmt = static_cast<SwCharFmt*>(pHt->GetCharFmt().GetCharFmt()); - if( pFmt && pOtherDoc ) + if (pOtherDoc) { pFmt = pOtherDoc->CopyCharFmt( *pFmt ); } commit 802b66210d551fe04225ce71025c34914b4b3b7d Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 10:01:18 2014 +0000 coverity#982311 Dead default in switch Change-Id: I59ab0c6883e7fc02bed2f4e286a83b6054d8ef3b diff --git a/svl/source/numbers/zformat.cxx b/svl/source/numbers/zformat.cxx index 6bf72257..a34778e 100644 --- a/svl/source/numbers/zformat.cxx +++ b/svl/source/numbers/zformat.cxx @@ -1502,7 +1502,6 @@ short SvNumberformat::ImpNextSymbol(OUStringBuffer& rString, case '=': eSymbolType = NUMBERFORMAT_OP_EQ; break; - default: break; } break; case ' ': commit 0aab188892b8e4b5e9f8c88dbd22ba6f1bc4d9dd Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 09:59:16 2014 +0000 coverity#1019315 Dead default in switch Change-Id: Iaac33534d5035ded00115f7a75e2c8720ccc3ea5 diff --git a/scaddins/source/analysis/analysishelper.cxx b/scaddins/source/analysis/analysishelper.cxx index 6e8643a..bf13aad 100644 --- a/scaddins/source/analysis/analysishelper.cxx +++ b/scaddins/source/analysis/analysishelper.cxx @@ -600,8 +600,6 @@ double GetYearFrac( sal_Int32 nNullDate, sal_Int32 nStartDate, sal_Int32 nEndDat case 3: // 3=exact/365 nDaysInYear = 365; break; - default: - throw lang::IllegalArgumentException(); } return double( nDayDiff ) / nDaysInYear; commit 65f8ce6d94e7fc4583f5c62980d63e1a329af7c8 Author: Caolán McNamara <[email protected]> Date: Tue Mar 25 09:42:50 2014 +0000 coverity#1187652 Dead default in switch Change-Id: Ieedec800955c0785b73caf52ff242b54246b653f diff --git a/framework/source/uiconfiguration/windowstateconfiguration.cxx b/framework/source/uiconfiguration/windowstateconfiguration.cxx index 4934d79..68472a4 100644 --- a/framework/source/uiconfiguration/windowstateconfiguration.cxx +++ b/framework/source/uiconfiguration/windowstateconfiguration.cxx @@ -1058,8 +1058,6 @@ void ConfigurationAccess_WindowState::impl_fillStructFromSequence( WindowStateIn case PROPERTY_CONTEXTACTIVE: rWinStateInfo.bContextActive = bValue; break; - default: - DBG_ASSERT( false, "Unknown boolean property in WindowState found!" ); } } }
_______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
