diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2019-11-24 20:26:22 +0100 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2019-11-24 21:46:23 +0100 |
commit | d2c9e289733df395b911a46c1028014f42e75f99 (patch) | |
tree | 49911788e81a04eb88de9159dbd2b6446f4655ba /linguistic | |
parent | 17c3d827e12d9ca99b869132f23ba212b11f909a (diff) |
cppcheck: performing init in init list (hwpfilter, i., l.)
Change-Id: Idf5b7be45d48076fbe191fbf1a2fa63c6da71902
Reviewed-on: https://gerrit.libreoffice.org/83617
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Diffstat (limited to 'linguistic')
-rw-r--r-- | linguistic/source/convdic.cxx | 20 | ||||
-rw-r--r-- | linguistic/source/convdicxml.cxx | 9 | ||||
-rw-r--r-- | linguistic/source/dlistimp.cxx | 5 | ||||
-rw-r--r-- | linguistic/source/gciterator.cxx | 2 | ||||
-rw-r--r-- | linguistic/workben/sprophelp.cxx | 8 | ||||
-rw-r--r-- | linguistic/workben/sspellimp.cxx | 6 |
6 files changed, 21 insertions, 29 deletions
diff --git a/linguistic/source/convdic.cxx b/linguistic/source/convdic.cxx index b07ea422a119..20ac65582078 100644 --- a/linguistic/source/convdic.cxx +++ b/linguistic/source/convdic.cxx @@ -149,24 +149,20 @@ ConvDic::ConvDic( sal_Int16 nConvType, bool bBiDirectional, const OUString &rMainURL) : - aFlushListeners( GetLinguMutex() ) -{ - aName = rName; - nLanguage = nLang; - nConversionType = nConvType; - aMainURL = rMainURL; + aFlushListeners( GetLinguMutex() ), + aMainURL(rMainURL), aName(rName), nLanguage(nLang), + nConversionType(nConvType), + nMaxLeftCharCount(0), nMaxRightCharCount(0), + bMaxCharCountIsValid(true), + bNeedEntries(true), + bIsModified(false), bIsActive(false) +{ if (bBiDirectional) pFromRight.reset( new ConvMap ); if (nLang == LANGUAGE_CHINESE_SIMPLIFIED || nLang == LANGUAGE_CHINESE_TRADITIONAL) pConvPropType.reset( new PropTypeMap ); - nMaxLeftCharCount = nMaxRightCharCount = 0; - bMaxCharCountIsValid = true; - - bNeedEntries = true; - bIsModified = bIsActive = false; - if( !rMainURL.isEmpty() ) { bool bExists = false; diff --git a/linguistic/source/convdicxml.cxx b/linguistic/source/convdicxml.cxx index ccd52688108e..c66ed32a9264 100644 --- a/linguistic/source/convdicxml.cxx +++ b/linguistic/source/convdicxml.cxx @@ -99,10 +99,9 @@ class ConvDicXMLDictionaryContext_Impl : public: ConvDicXMLDictionaryContext_Impl( ConvDicXMLImport &rImport ) : - ConvDicXMLImportContext( rImport ) + ConvDicXMLImportContext( rImport ), + nLanguage(LANGUAGE_NONE), nConversionType(-1) { - nLanguage = LANGUAGE_NONE; - nConversionType = -1; } // SvXMLImportContext @@ -347,10 +346,8 @@ void ConvDicXMLExport::ExportContent_() //!! see comment for pDic member ConvDicXMLImport::ConvDicXMLImport( ConvDic *pConvDic ) : SvXMLImport ( comphelper::getProcessComponentContext(), "com.sun.star.lingu2.ConvDicXMLImport", SvXMLImportFlags::ALL ), - pDic ( pConvDic ) + pDic ( pConvDic ), nLanguage(LANGUAGE_NONE), nConversionType(-1) { - nLanguage = LANGUAGE_NONE; - nConversionType = -1; GetNamespaceMap().Add( GetXMLToken(XML_NP_TCD), GetXMLToken(XML_N_TCD), XML_NAMESPACE_TCD); } diff --git a/linguistic/source/dlistimp.cxx b/linguistic/source/dlistimp.cxx index d97957a304b9..abe2aa291efd 100644 --- a/linguistic/source/dlistimp.cxx +++ b/linguistic/source/dlistimp.cxx @@ -102,10 +102,9 @@ public: DicEvtListenerHelper::DicEvtListenerHelper( const uno::Reference< XDictionaryList > &rxDicList ) : aDicListEvtListeners ( GetLinguMutex() ), - xMyDicList ( rxDicList ) + xMyDicList ( rxDicList ), + nCondensedEvt(0), nNumCollectEvtListeners(0) { - nCondensedEvt = 0; - nNumCollectEvtListeners = 0; } diff --git a/linguistic/source/gciterator.cxx b/linguistic/source/gciterator.cxx index 81c1ce99d9c4..95624a9ccd38 100644 --- a/linguistic/source/gciterator.cxx +++ b/linguistic/source/gciterator.cxx @@ -277,10 +277,10 @@ GrammarCheckingIterator::GrammarCheckingIterator() : m_aCurCheckedDocId(), m_bGCServicesChecked( false ), m_nDocIdCounter( 0 ), + m_thread(nullptr), m_aEventListeners( MyMutex::get() ), m_aNotifyListeners( MyMutex::get() ) { - m_thread = nullptr; } diff --git a/linguistic/workben/sprophelp.cxx b/linguistic/workben/sprophelp.cxx index e957a06742fe..41542fec155f 100644 --- a/linguistic/workben/sprophelp.cxx +++ b/linguistic/workben/sprophelp.cxx @@ -57,13 +57,13 @@ PropertyChgHelper::PropertyChgHelper( PropertyChgHelper::PropertyChgHelper( const PropertyChgHelper &rHelper ) : - aLngSvcEvtListeners (GetLinguMutex()) + aPropNames(rHelper.aPropNames), + xMyEvtObj(rHelper.xMyEvtObj), + aLngSvcEvtListeners (GetLinguMutex()), + xPropSet(rHelper.xPropSet) { - xPropSet = rHelper.xPropSet; - aPropNames = rHelper.aPropNames; AddAsPropListener(); - xMyEvtObj = rHelper.xMyEvtObj; } diff --git a/linguistic/workben/sspellimp.cxx b/linguistic/workben/sspellimp.cxx index 51d9c14abf0e..6cfc89cef298 100644 --- a/linguistic/workben/sspellimp.cxx +++ b/linguistic/workben/sspellimp.cxx @@ -50,10 +50,10 @@ sal_Bool operator == ( const Locale &rL1, const Locale &rL2 ) SpellChecker::SpellChecker() : - aEvtListeners ( GetLinguMutex() ) + aEvtListeners ( GetLinguMutex() ), + pPropHelper(NULL), + bDisposing(sal_False) { - bDisposing = sal_False; - pPropHelper = NULL; } |