diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-02-20 19:41:29 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-02-21 07:35:02 +0100 |
commit | 41242d35df47ec8fd6b20e7779a4e650aa83cdfb (patch) | |
tree | 43f10b9cec155c8a5ed4c0fcc6f1a441a92b6715 /sc | |
parent | f34942333ffe1117253a761732a8f65aac4f11b0 (diff) |
loplugin:subtlezeroinit: sc
Change-Id: I98e433441e97d0f2e88f84cd9b3cf91861465bff
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/data/funcdesc.cxx | 4 | ||||
-rw-r--r-- | sc/source/core/tool/adiasync.cxx | 2 | ||||
-rw-r--r-- | sc/source/core/tool/calcconfig.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/excel/impop.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/excel/xestyle.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/html/htmlexp.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlcelli.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlexprt.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlimprt.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlimprt.hxx | 6 | ||||
-rw-r--r-- | sc/source/ui/unoobj/chart2uno.cxx | 4 |
11 files changed, 15 insertions, 15 deletions
diff --git a/sc/source/core/data/funcdesc.cxx b/sc/source/core/data/funcdesc.cxx index 9be95e78090e..d745eaaf63ea 100644 --- a/sc/source/core/data/funcdesc.cxx +++ b/sc/source/core/data/funcdesc.cxx @@ -1074,7 +1074,7 @@ ScFunctionMgr::ScFunctionMgr() : OSL_ENSURE( pFuncList, "Functionlist not found." ); sal_uInt32 catCount[MAX_FUNCCAT] = {0}; - aCatLists[0] = new ::std::vector<const ScFuncDesc*>(); + aCatLists[0] = new ::std::vector<const ScFuncDesc*>; aCatLists[0]->reserve(pFuncList->GetCount()); // Retrieve all functions, store in cumulative ("All") category, and count @@ -1093,7 +1093,7 @@ ScFunctionMgr::ScFunctionMgr() : // Allocate correct amount of space for categories for (sal_uInt16 i = 1; i < MAX_FUNCCAT; ++i) { - aCatLists[i] = new ::std::vector<const ScFuncDesc*>(); + aCatLists[i] = new ::std::vector<const ScFuncDesc*>; aCatLists[i]->reserve(catCount[i]); } diff --git a/sc/source/core/tool/adiasync.cxx b/sc/source/core/tool/adiasync.cxx index 7d2150fc4811..ee531d5bcdc3 100644 --- a/sc/source/core/tool/adiasync.cxx +++ b/sc/source/core/tool/adiasync.cxx @@ -48,7 +48,7 @@ ScAddInAsync::ScAddInAsync(sal_uLong nHandleP, LegacyFuncData* pFuncData, ScDocu meType(pFuncData->GetAsyncType()), bValid( false ) { - pDocs = new ScAddInDocs(); + pDocs = new ScAddInDocs; pDocs->insert( pDoc ); theAddInAsyncTbl.insert( this ); } diff --git a/sc/source/core/tool/calcconfig.cxx b/sc/source/core/tool/calcconfig.cxx index c7cb013de8aa..2a0b1f305276 100644 --- a/sc/source/core/tool/calcconfig.cxx +++ b/sc/source/core/tool/calcconfig.cxx @@ -170,7 +170,7 @@ OUString ScOpCodeSetToSymbolicString(const ScCalcConfig::OpCodeSet& rOpCodes) ScCalcConfig::OpCodeSet ScStringToOpCodeSet(const OUString& rOpCodes) { - ScCalcConfig::OpCodeSet result(new std::set< OpCode >()); + ScCalcConfig::OpCodeSet result(new std::set< OpCode >); formula::FormulaCompiler aCompiler; formula::FormulaCompiler::OpCodeMapPtr pOpCodeMap(aCompiler.GetOpCodeMap(css::sheet::FormulaLanguage::ENGLISH)); diff --git a/sc/source/filter/excel/impop.cxx b/sc/source/filter/excel/impop.cxx index 16837e0809ec..ba26604d3568 100644 --- a/sc/source/filter/excel/impop.cxx +++ b/sc/source/filter/excel/impop.cxx @@ -130,7 +130,7 @@ ImportExcel::ImportExcel( XclImpRootData& rImpData, SvStream& rStrm ): pExcRoot->pShrfmlaBuff = new SharedFormulaBuffer( pExcRoot ); //&aShrfrmlaBuff; pExcRoot->pExtNameBuff = new ExtNameBuff ( *this ); - pOutlineListBuffer = new XclImpOutlineListBuffer( ); + pOutlineListBuffer = new XclImpOutlineListBuffer; // ab Biff8 pFormConv = pExcRoot->pFmlaConverter = new ExcelToSc( GetRoot() ); diff --git a/sc/source/filter/excel/xestyle.cxx b/sc/source/filter/excel/xestyle.cxx index f13aa29b07f5..1bb6619eb4a8 100644 --- a/sc/source/filter/excel/xestyle.cxx +++ b/sc/source/filter/excel/xestyle.cxx @@ -3032,7 +3032,7 @@ XclExpDxfs::XclExpDxfs( const XclExpRoot& rRoot ) pCellProt = nullptr; } - XclExpColor* pColor = new XclExpColor(); + XclExpColor* pColor = new XclExpColor; if(!pColor->FillFromItemSet( rSet )) { delete pColor; diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx index 9f7bc261275e..3f2ef7ed02f0 100644 --- a/sc/source/filter/html/htmlexp.cxx +++ b/sc/source/filter/html/htmlexp.cxx @@ -1285,7 +1285,7 @@ void ScHTMLExport::CopyLocalFileToINet( OUString& rFileNm, } else { - pFileNameMap.reset( new std::map<OUString, OUString>() ); + pFileNameMap.reset( new std::map<OUString, OUString> ); } bool bRet = false; diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx index f5e2ee144e82..f48cad0154be 100644 --- a/sc/source/filter/xml/xmlcelli.cxx +++ b/sc/source/filter/xml/xmlcelli.cxx @@ -682,7 +682,7 @@ SvXMLImportContext *ScXMLTableRowCellContext::CreateChildContext( sal_uInt16 nPr { bIsEmpty = false; if (!pDetectiveObjVec) - pDetectiveObjVec = new ScMyImpDetectiveObjVec(); + pDetectiveObjVec = new ScMyImpDetectiveObjVec; pContext = new ScXMLDetectiveContext( rXMLImport, nPrefix, rLName, pDetectiveObjVec ); } diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index c7f169fc45f6..01e88a37c5bb 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -367,7 +367,7 @@ ScXMLExport::ScXMLExport( pMergedRangesContainer = new ScMyMergedRangesContainer(); pValidationsContainer = new ScMyValidationsContainer(); mpCellsItr.reset(new ScMyNotEmptyCellsIterator(*this)); - pDefaults = new ScMyDefaultStyles(); + pDefaults = new ScMyDefaultStyles; } pCellStyles = new ScFormatRangeStyles(); diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx index 0832f3df3936..34208af4b299 100644 --- a/sc/source/filter/xml/xmlimprt.cxx +++ b/sc/source/filter/xml/xmlimprt.cxx @@ -3040,7 +3040,7 @@ XMLNumberFormatAttributesExportHelper* ScXMLImport::GetNumberFormatAttributesExp ScMyStyleNumberFormats* ScXMLImport::GetStyleNumberFormats() { if (!pStyleNumberFormats) - pStyleNumberFormats = new ScMyStyleNumberFormats(); + pStyleNumberFormats = new ScMyStyleNumberFormats; return pStyleNumberFormats; } diff --git a/sc/source/filter/xml/xmlimprt.hxx b/sc/source/filter/xml/xmlimprt.hxx index 0a0c8f73ef0a..e11e61e5558c 100644 --- a/sc/source/filter/xml/xmlimprt.hxx +++ b/sc/source/filter/xml/xmlimprt.hxx @@ -1096,7 +1096,7 @@ public: void AddNamedExpression(ScMyNamedExpression* pMyNamedExpression) { if (!m_pMyNamedExpressions) - m_pMyNamedExpressions = new ScMyNamedExpressions(); + m_pMyNamedExpressions = new ScMyNamedExpressions; m_pMyNamedExpressions->push_back(std::unique_ptr<ScMyNamedExpression>(pMyNamedExpression)); } @@ -1104,12 +1104,12 @@ public: void AddLabelRange(const ScMyLabelRange* pMyLabelRange) { if (!pMyLabelRanges) - pMyLabelRanges = new ScMyLabelRanges(); + pMyLabelRanges = new ScMyLabelRanges; pMyLabelRanges->push_back(pMyLabelRange); } void AddValidation(const ScMyImportValidation& rValidation) { if (!pValidations) - pValidations = new ScMyImportValidations(); + pValidations = new ScMyImportValidations; pValidations->push_back(rValidation); } bool GetValidation(const OUString& sName, ScMyImportValidation& aValidation); diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx index d8c03f47dbab..8c302a68974f 100644 --- a/sc/source/ui/unoobj/chart2uno.cxx +++ b/sc/source/ui/unoobj/chart2uno.cxx @@ -1611,7 +1611,7 @@ class InsertTabNumber : public unary_function<ScTokenRef, void> { public: InsertTabNumber() : - mpTabNumList(new list<SCTAB>()) + mpTabNumList(new list<SCTAB>) { } @@ -2780,7 +2780,7 @@ void ScChart2DataSequence::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint // updated, and bring the change back to the token list. ScRangeList aRanges; - m_pRangeIndices.reset(new vector<sal_uInt32>()); + m_pRangeIndices.reset(new vector<sal_uInt32>); vector<ScTokenRef>::const_iterator itrBeg = m_aTokens.begin(), itrEnd = m_aTokens.end(); for (vector<ScTokenRef>::const_iterator itr = itrBeg ;itr != itrEnd; ++itr) { |