incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject svn commit: r1362907 - in /incubator/ooo/trunk/main: binfilter/bf_sc/source/core/data/ binfilter/bf_starmath/source/ binfilter/bf_svx/source/engine3d/ binfilter/bf_svx/source/items/ binfilter/bf_sw/source/core/doc/ binfilter/bf_sw/source/core/layout/ b...
Date Wed, 18 Jul 2012 12:25:26 GMT
Author: alg
Date: Wed Jul 18 12:25:25 2012
New Revision: 1362907

URL: http://svn.apache.org/viewvc?rev=1362907&view=rev
Log:
binfilter, editeng: fix some warnings
Patch by: Michael Stahl

Modified:
    incubator/ooo/trunk/main/binfilter/bf_sc/source/core/data/sc_pivot.cxx
    incubator/ooo/trunk/main/binfilter/bf_starmath/source/starmath_parse.cxx
    incubator/ooo/trunk/main/binfilter/bf_svx/source/engine3d/svx_lathe3d.cxx
    incubator/ooo/trunk/main/binfilter/bf_svx/source/items/svx_xmlcnitm.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/layout/sw_frmtool.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/swg/sw_rdnum.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_porfly.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_widorp.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unostyle.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/w4w/sw_w4wpar1.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlimpit.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlithlp.cxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/xmlithlp.hxx
    incubator/ooo/trunk/main/binfilter/bf_sw/source/ui/config/sw_fontcfg.cxx
    incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_XMLTextMarkImportContext.cxx
    incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_txtvfldi.cxx
    incubator/ooo/trunk/main/editeng/source/items/xmlcnitm.cxx

Modified: incubator/ooo/trunk/main/binfilter/bf_sc/source/core/data/sc_pivot.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sc/source/core/data/sc_pivot.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sc/source/core/data/sc_pivot.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sc/source/core/data/sc_pivot.cxx Wed Jul 18 12:25:25
2012
@@ -761,7 +761,7 @@ static const USHORT nFuncMaskArr[PIVOT_M
 /*?*/ 			DBG_ASSERT(nIndex < PIVOT_MAXFIELD, "no data field (GPF in old versions!)");
 /*?*/ 			if ( nIndex < PIVOT_MAXFIELD )
 /*?*/ 			{
-/*?*/ 				memcpy(&aColArr[nIndex], &aColArr[nIndex+1], (PIVOT_MAXFIELD - nIndex -
1) * sizeof(PivotField));
+/*?*/ 				memmove(&aColArr[nIndex], &aColArr[nIndex+1], (PIVOT_MAXFIELD - nIndex
- 1) * sizeof(PivotField));
 /*?*/ 				aColArr[nColCount-1] = aField;
 /*?*/ 				pDataList = pColList[nColCount-1];
 /*?*/ 			}
@@ -781,7 +781,7 @@ static const USHORT nFuncMaskArr[PIVOT_M
 /*?*/ 			DBG_ASSERT(nIndex < PIVOT_MAXFIELD, "no data field (GPF in old versions!)");
 /*?*/ 			if ( nIndex < PIVOT_MAXFIELD )
 /*?*/ 			{
-/*?*/ 				memcpy(&aRowArr[nIndex], &aRowArr[nIndex+1], (PIVOT_MAXFIELD - nIndex -
1) * sizeof(PivotField));
+/*?*/ 				memmove(&aRowArr[nIndex], &aRowArr[nIndex+1], (PIVOT_MAXFIELD - nIndex
- 1) * sizeof(PivotField));
 /*?*/ 				aRowArr[nRowCount-1] = aField;
 /*?*/ 				pDataList = pRowList[nRowCount-1];
 /*?*/ 			}

Modified: incubator/ooo/trunk/main/binfilter/bf_starmath/source/starmath_parse.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_starmath/source/starmath_parse.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_starmath/source/starmath_parse.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_starmath/source/starmath_parse.cxx Wed Jul 18 12:25:25
2012
@@ -1636,7 +1636,7 @@ const sal_Int32 coNumContFlags =
 /*N*/ 	BOOL		 bIsPostfix = eType == TFACT;
 /*N*/ 
 /*N*/ 	SmStructureNode *pSNode;
-/*N*/ 	SmNode *pOper,
+/*N*/ 	SmNode *pOper = 0,
 /*N*/ 		   *pExtra = 0,
 /*N*/ 		   *pArg;
 /*N*/ 

Modified: incubator/ooo/trunk/main/binfilter/bf_svx/source/engine3d/svx_lathe3d.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_svx/source/engine3d/svx_lathe3d.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_svx/source/engine3d/svx_lathe3d.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_svx/source/engine3d/svx_lathe3d.cxx Wed Jul 18 12:25:25
2012
@@ -193,7 +193,7 @@ namespace binfilter {
 /*N*/ 		Matrix4D aRotMat;
 /*N*/ 
 /*N*/ 		// Skalierung vorbereiten
-/*N*/ 		double fScalePerStep;
+/*N*/ 		double fScalePerStep(0.0);
 /*N*/ 		if(GetBackScale() != 100)
 /*N*/ 			fScalePerStep = (((double)GetBackScale() - 100.0) / 100.0) / (double)GetHorizontalSegments();
 /*N*/ 

Modified: incubator/ooo/trunk/main/binfilter/bf_svx/source/items/svx_xmlcnitm.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_svx/source/items/svx_xmlcnitm.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_svx/source/items/svx_xmlcnitm.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_svx/source/items/svx_xmlcnitm.cxx Wed Jul 18 12:25:25
2012
@@ -21,6 +21,8 @@
 
 
 
+#include <memory>
+
 #ifndef _COM_SUN_STAR_XML_ATTRIBUTEDATA_HPP_
 #include <com/sun/star/xml/AttributeData.hpp>
 #endif
@@ -108,7 +110,7 @@ using namespace ::com::sun::star::xml;
 /*NBFF*/ 	}
 /*NBFF*/ 	else
 /*NBFF*/ 	{
-/*NBFF*/ 		SvXMLAttrContainerData* pNewImpl = new SvXMLAttrContainerData;
+/*NBFF*/ 		::std::auto_ptr<SvXMLAttrContainerData> pNewImpl(new SvXMLAttrContainerData);
 /*NBFF*/ 
 /*NBFF*/ 		try
 /*NBFF*/ 		{
@@ -158,17 +160,15 @@ using namespace ::com::sun::star::xml;
 /*NBFF*/ 			if( nAttr == nCount )
 /*NBFF*/ 			{
 /*NBFF*/ 				delete pImpl;
-/*NBFF*/ 				pImpl = pNewImpl;
-/*NBFF*/ 				return FALSE;
+/*NBFF*/ 				pImpl = pNewImpl.release();
 /*NBFF*/ 			}
 /*NBFF*/ 			else
 /*NBFF*/ 			{
-/*NBFF*/ 				delete pNewImpl;
+/*NBFF*/ 				return FALSE;
 /*NBFF*/ 			}
 /*NBFF*/ 		}
 /*NBFF*/ 		catch(...)
 /*NBFF*/ 		{
-/*NBFF*/ 			delete pNewImpl;
 /*NBFF*/ 			return FALSE;
 /*NBFF*/ 		}
 /*NBFF*/ 	}

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx Wed
Jul 18 12:25:25 2012
@@ -353,7 +353,7 @@ const struct SwTableEntry NumRuleProgNam
 /*N*/ }
 /*N*/ const NameToIdHash & SwStyleNameMapper::getHashTable ( SwGetPoolIdFromName eFlags,
sal_Bool bProgName )
 /*N*/ {
-/*N*/ 	NameToIdHash *pHash;
+/*N*/ 	NameToIdHash *pHash(0);
 /*N*/ 	const SvStringsDtor *pStrings;
 /*N*/ 
 /*N*/ 	switch ( eFlags )

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/layout/sw_frmtool.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/layout/sw_frmtool.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/layout/sw_frmtool.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/layout/sw_frmtool.cxx Wed Jul 18
12:25:25 2012
@@ -1650,7 +1650,7 @@ void MakeFrms( SwDoc *pDoc, const SwNode
 			}
 			else
 			{
-				BOOL bSplit;
+				BOOL bSplit(false);
 				SwFrm* pPrv = bApres ? pFrm : pFrm->GetPrev();
 				// Wenn in einen SectionFrm ein anderer eingefuegt wird,
 				// muss dieser aufgebrochen werden

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/swg/sw_rdnum.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/swg/sw_rdnum.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/swg/sw_rdnum.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/swg/sw_rdnum.cxx Wed Jul 18 12:25:25
2012
@@ -158,13 +158,16 @@ SwNumRule* SwSwgReader::InNumRule()
         SwNumFmt aFmt;
         if( r.cur() != SWG_NUMFMT )
         {
-            Error(); delete pRule; return NULL;
+            Error();
+            delete pRule;
+            return NULL;
         }
         aFmt.SetBulletFont( NULL );
         InNumFmt( aFmt );
         if( !r )
         {
-            delete pRule; return NULL;
+            delete pRule;
+            return NULL;
         }
         pRule->Set( (USHORT) cFmt[ i ], aFmt );
     }
@@ -181,8 +184,8 @@ SwNumRule* SwSwgReader::InNumRule()
                 {
                     SwNumFmt aFmt( pRule->Get( i ) );
                     aFmt.SetIncludeUpperLevels( MAXLEVEL );
-                    aFmt.SetAbsLSpace( aOldLft[ i ] );
-                    aFmt.SetFirstLineOffset( aOldFI[ i ] );
+                    aFmt.SetAbsLSpace( aOldLft[ (i < 5) ? i : 4 ] );
+                    aFmt.SetFirstLineOffset( aOldFI[ (i < 5) ? i : 4 ] );
                     aFmt.SetNumberingType(SVX_NUM_ARABIC);
                     if( i )
                         aFmt.SetSuffix( aEmptyStr );

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_porfly.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_porfly.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_porfly.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_porfly.cxx Wed Jul 18 12:25:25
2012
@@ -354,7 +354,7 @@ namespace binfilter {
 /*N*/ 	//Die vertikale Position wird berechnet, die relative horizontale
 /*N*/ 	//Position ist stets 0.
 /*N*/ 
-/*N*/ 	SdrObject *pSdrObj;
+/*N*/ 	SdrObject *pSdrObj(0);
 /*N*/ 	SwRect aBoundRect;
 /*N*/ 	long nOldWidth;
 /*N*/ 	if( bDraw )

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_widorp.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_widorp.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_widorp.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/text/sw_widorp.cxx Wed Jul 18 12:25:25
2012
@@ -141,7 +141,7 @@ namespace binfilter {
 /*N*/     SWRECTFN( pFrm )
 /*N*/     // nOrigin is an absolut value, rLine referes to the swapped situation.
 /*N*/ 
-/*N*/     SwTwips nTmpY;
+/*N*/     SwTwips nTmpY(0);
 /*N*/     if ( pFrm->IsVertical() )
 				{DBG_BF_ASSERT(0, "STRIP");} //STRIP001 /*?*/         nTmpY = pFrm->SwitchHorizontalToVertical(
rLine.Y() + rLine.GetLineHeight() );
 /*N*/     else
@@ -391,7 +391,7 @@ sal_Bool SwTxtFrmBreak::WouldFit( SwTxtM
 /*N*/     SWRECTFN( pFrm )
 /*N*/ 
 /*N*/     const SwTwips nDocPrtTop = (pFrm->*fnRect->fnGetPrtTop)();
-/*N*/     SwTwips nOldHeight;
+/*N*/     SwTwips nOldHeight(0);
 /*N*/     SwTwips nTmpY = rLine.Y() + rLine.GetLineHeight();
 /*N*/ 
 /*N*/     if ( bVert )

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx Wed Jul 18
12:25:25 2012
@@ -462,7 +462,7 @@ void SwXDocumentIndex::setPropertyValue(
     if ( pMap->nFlags & PropertyAttribute::READONLY)
         throw PropertyVetoException ( OUString ( RTL_CONSTASCII_USTRINGPARAM ( "Property
is read-only: " ) ) + rPropertyName, static_cast < cppu::OWeakObject * > ( this ) );
 
-	SwTOXBase* pTOXBase;
+	SwTOXBase* pTOXBase(0);
 	if(GetFmt())
 		pTOXBase = (SwTOXBaseSection*)GetFmt()->GetSection();
 	else if(bIsDescriptor)
@@ -749,7 +749,7 @@ uno::Any SwXDocumentIndex::getPropertyVa
 													_pMap, rPropertyName);
     if (!pMap)
         throw UnknownPropertyException(OUString ( RTL_CONSTASCII_USTRINGPARAM ( "Unknown
property: " ) ) + rPropertyName, static_cast < cppu::OWeakObject * > ( this ) );
-	SwTOXBase* pTOXBase;
+	SwTOXBase* pTOXBase(0);
 	if(GetFmt())
 		pTOXBase = (SwTOXBaseSection*)GetFmt()->GetSection();
 	else if(bIsDescriptor)

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unostyle.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unostyle.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unostyle.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/core/unocore/sw_unostyle.cxx Wed Jul 18
12:25:25 2012
@@ -1377,7 +1377,7 @@ SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyl
 	Reference < XNameAccess > xFamilies = xFamilySupplier->getStyleFamilies();
 
 	Any aAny;
-    sal_uInt16 nMapId;
+    sal_uInt16 nMapId(PROPERTY_MAP_CHAR_STYLE);
     switch( eFamily )
     {
         case SFX_STYLE_FAMILY_CHAR:
@@ -1415,6 +1415,11 @@ SwXStyle::SwXStyle( SwDoc *pDoc, SfxStyl
 			nMapId = PROPERTY_MAP_NUM_STYLE;
 		}
 		break;
+        default:
+        {
+            OSL_ASSERT(false);
+        }
+        break;
     }
     pPropImpl = new SwStyleProperties_Impl(aSwMapProvider.GetPropertyMap(nMapId));
 }

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/w4w/sw_w4wpar1.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/w4w/sw_w4wpar1.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/w4w/sw_w4wpar1.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/w4w/sw_w4wpar1.cxx Wed Jul 18 12:25:25
2012
@@ -1208,7 +1208,7 @@ BYTE SwW4WParser::GetDeciByte( BYTE& rBy
 	register BOOL Ok = FALSE;
 	BYTE nCode;
 
-	while( this )
+	while (true)
 	{
 		n =  ReadChar();
 		if ( '0' > n || '9' < n )   // eof durch 0 abgedeckt
@@ -1260,6 +1260,7 @@ BYTE SwW4WParser::GetHexByte( BYTE& rHex
 	if( c1 >= '0' && c1 <= '9' )        nRet = (c1 - '0');
 	else if( c1 >= 'A' && c1 <= 'F' )   nRet = (c1 - 'A' + 10);
 	else if( c1 >= 'a' && c1 <= 'f' )   nRet = (c1 - 'a' + 10);
+    else { return 0; }
 
 	if( W4WR_RED == c2 || W4WR_TXTERM == c2 ){
 		rHexVal = (BYTE)nRet;
@@ -2483,7 +2484,8 @@ void SwW4WParser::Read_NewTabTable()		//
 				BYTE nType = aTabTypesArr[ nTabPos / 2 ];
 
 				nTmp = nTabPos & 1 ? nType & 0x0f : (nType & 0xf0) >> 4;
-				if (nTmp <= 4){ 		// no virtual Tab
+                if (nTmp < (sizeof(aAdjustArr)/sizeof(aAdjustArr[0])))
+                {       // no virtual Tab
 					aTabStop.GetAdjustment() = aAdjustArr[nTmp];
 
 					if( bTabLeadings && aTabLeadingArr[ nTabPos ] )

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlimpit.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlimpit.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlimpit.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlimpit.cxx Wed Jul 18
12:25:25 2012
@@ -576,7 +576,8 @@ sal_Bool SvXMLImportItemMapper::PutXMLVa
                                                         DEF_LINE_WIDTH_4 ) )
                         return sal_False;
 
-                    sal_uInt16 nSize = sizeof( aDBorderWidths );
+                    sal_uInt16 const nSize =
+                        sizeof(aDBorderWidths)/sizeof(aDBorderWidths[0]);
 					sal_uInt16 i=0;
                     for( i=0; i < nSize; i += 4 )
                     {

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlithlp.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlithlp.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlithlp.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/sw_xmlithlp.cxx Wed Jul 18
12:25:25 2012
@@ -158,7 +158,7 @@ const sal_uInt16 aSBorderWidths[] =
         SBORDER_ENTRY( 3 ), SBORDER_ENTRY( 4 )
 };
 
-const sal_uInt16 aDBorderWidths[5*11] =
+const sal_uInt16 aDBorderWidths[4*11] =
 {
         DBORDER_ENTRY( 0 ),
         DBORDER_ENTRY( 7 ),

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/xmlithlp.hxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/xmlithlp.hxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/xmlithlp.hxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/filter/xml/xmlithlp.hxx Wed Jul 18 12:25:25
2012
@@ -94,7 +94,7 @@ void lcl_frmitems_MergeXMLVertPos( SvxGr
 							  	   SvxGraphicPosition eVert );
 
 extern const sal_uInt16 aSBorderWidths[];
-extern const sal_uInt16 aDBorderWidths[5*11];
+extern const sal_uInt16 aDBorderWidths[4*11];
 
 extern const struct SvXMLEnumMapEntry psXML_BorderStyles[];
 extern const struct SvXMLEnumMapEntry psXML_NamedBorderWidths[];

Modified: incubator/ooo/trunk/main/binfilter/bf_sw/source/ui/config/sw_fontcfg.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_sw/source/ui/config/sw_fontcfg.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_sw/source/ui/config/sw_fontcfg.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_sw/source/ui/config/sw_fontcfg.cxx Wed Jul 18 12:25:25
2012
@@ -140,7 +140,7 @@ using namespace ::com::sun::star::uno;
 --------------------------------------------------*/
 /*M*/ BOOL SwStdFontConfig::IsFontDefault(USHORT nFontType) const
 /*M*/ {
-/*M*/ 	BOOL bSame;
+/*M*/ 	BOOL bSame(false);
 /*M*/     SvtLinguOptions aLinguOpt;
 /*N*/ 
 /*N*/ 	// #107253# Replaced SvtLinguConfig with SwLinguConfig wrapper with UsageCount

Modified: incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_XMLTextMarkImportContext.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_XMLTextMarkImportContext.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_XMLTextMarkImportContext.cxx
(original)
+++ incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_XMLTextMarkImportContext.cxx
Wed Jul 18 12:25:25 2012
@@ -226,7 +226,7 @@ sal_Bool XMLTextMarkImportContext::FindN
 	const Reference<XAttributeList> & xAttrList,
 	OUString& sName)
 {
-	sal_Bool bNameOK;
+	sal_Bool bNameOK(sal_False);
 
 	// find name attribute first
 	sal_Int16 nLength = xAttrList->getLength();

Modified: incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_txtvfldi.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_txtvfldi.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_txtvfldi.cxx (original)
+++ incubator/ooo/trunk/main/binfilter/bf_xmloff/source/text/xmloff_txtvfldi.cxx Wed Jul 18
12:25:25 2012
@@ -808,6 +808,8 @@ SvXMLImportContext* XMLVariableDeclsImpo
                 break;
             default:
                 DBG_ERROR("unknown field type!");
+                eElementName = XML_SEQUENCE_DECL;
+                break;
         }
 
 		if( IsXMLToken( rLocalName, eElementName ) )

Modified: incubator/ooo/trunk/main/editeng/source/items/xmlcnitm.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/editeng/source/items/xmlcnitm.cxx?rev=1362907&r1=1362906&r2=1362907&view=diff
==============================================================================
--- incubator/ooo/trunk/main/editeng/source/items/xmlcnitm.cxx (original)
+++ incubator/ooo/trunk/main/editeng/source/items/xmlcnitm.cxx Wed Jul 18 12:25:25 2012
@@ -23,6 +23,9 @@
 
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_editeng.hxx"
+
+#include <memory>
+
 #include <com/sun/star/xml/AttributeData.hpp>
 #include <com/sun/star/lang/XUnoTunnel.hpp>
 #include <xmloff/xmlcnimp.hxx>
@@ -114,7 +117,8 @@ sal_Bool SvXMLAttrContainerItem::PutValu
 	}
 	else
 	{
-		SvXMLAttrContainerData* pNewImpl = new SvXMLAttrContainerData;
+        ::std::auto_ptr<SvXMLAttrContainerData> pNewImpl(
+            new SvXMLAttrContainerData);
 
 		try
 		{
@@ -165,17 +169,15 @@ sal_Bool SvXMLAttrContainerItem::PutValu
 			if( nAttr == nCount )
 			{
 				delete pImpl;
-                pImpl = pNewImpl;
+                pImpl = pNewImpl.release();
 			}
 			else
 			{
-				delete pNewImpl;
 				return sal_False;
 			}
 		}
 		catch(...)
 		{
-			delete pNewImpl;
 			return sal_False;
 		}
 	}



Mime
View raw message