diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-07-25 13:56:57 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-07-26 08:31:55 +0200 |
commit | ba42d00ed5a04850f88abdf184a4855db7cf2700 (patch) | |
tree | af8ec0b48accf0abb7dce9f0fb0194cd60440e14 /l10ntools | |
parent | ee025b744ac9efafe7c083ed80f8e2cc7cb3e2c1 (diff) |
loplugin:returnconstant in sal,l10ntools,sot
Change-Id: I3f4e4efa8ea839f48b9700ebc26c7e5ab279ce49
Reviewed-on: https://gerrit.libreoffice.org/57975
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'l10ntools')
-rw-r--r-- | l10ntools/inc/helpmerge.hxx | 2 | ||||
-rw-r--r-- | l10ntools/inc/lngmerge.hxx | 4 | ||||
-rw-r--r-- | l10ntools/inc/xmlparse.hxx | 2 | ||||
-rw-r--r-- | l10ntools/source/helpmerge.cxx | 7 | ||||
-rw-r--r-- | l10ntools/source/lngmerge.cxx | 6 | ||||
-rw-r--r-- | l10ntools/source/xmlparse.cxx | 3 |
6 files changed, 10 insertions, 14 deletions
diff --git a/l10ntools/inc/helpmerge.hxx b/l10ntools/inc/helpmerge.hxx index 5837cc2f7765..99c9270df9fe 100644 --- a/l10ntools/inc/helpmerge.hxx +++ b/l10ntools/inc/helpmerge.hxx @@ -52,7 +52,7 @@ public: const OString& sLanguage , MergeDataFile* pMergeDataFile ); private: - bool MergeSingleFile( XMLFile* file , MergeDataFile* pMergeDataFile , const OString& sLanguage , OString const & sPath ); + void MergeSingleFile( XMLFile* file , MergeDataFile* pMergeDataFile , const OString& sLanguage , OString const & sPath ); static void ProcessHelp( LangHashMap* aLangHM , const OString& sCur , ResData *pResData , MergeDataFile* pMergeDataFile ); }; diff --git a/l10ntools/inc/lngmerge.hxx b/l10ntools/inc/lngmerge.hxx index 35c7868b01a3..56eaec71b11d 100644 --- a/l10ntools/inc/lngmerge.hxx +++ b/l10ntools/inc/lngmerge.hxx @@ -54,8 +54,8 @@ public: LngParser(const OString &rLngFile); ~LngParser(); - bool CreatePO( const OString &rPOFile ); - bool Merge(const OString &rPOFile, const OString &rDestinationFile, + void CreatePO( const OString &rPOFile ); + void Merge(const OString &rPOFile, const OString &rDestinationFile, const OString &rLanguage ); }; diff --git a/l10ntools/inc/xmlparse.hxx b/l10ntools/inc/xmlparse.hxx index 04f150d5d674..027076f39725 100644 --- a/l10ntools/inc/xmlparse.hxx +++ b/l10ntools/inc/xmlparse.hxx @@ -157,7 +157,7 @@ public: XMLHashMap* GetStrings(){ return m_pXMLStrings.get(); } void Write( OString const &rFilename ); - bool Write( std::ofstream &rStream, XMLNode *pCur = nullptr ); + void Write( std::ofstream &rStream, XMLNode *pCur = nullptr ); bool CheckExportStatus( XMLParentNode *pCur = nullptr ); diff --git a/l10ntools/source/helpmerge.cxx b/l10ntools/source/helpmerge.cxx index 92f5171e5e67..0a2e3c3dfd52 100644 --- a/l10ntools/source/helpmerge.cxx +++ b/l10ntools/source/helpmerge.cxx @@ -156,12 +156,12 @@ bool HelpParser::Merge( const OString &rDestinationFile, SAL_WARN("l10ntools", "could not parse " << sHelpFile); return false; } - bool hasNoError = MergeSingleFile( xmlfile , pMergeDataFile , rLanguage , rDestinationFile ); + MergeSingleFile( xmlfile , pMergeDataFile , rLanguage , rDestinationFile ); delete xmlfile; - return hasNoError; + return true; } -bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile* pMergeDataFile , const OString& sLanguage , +void HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile* pMergeDataFile , const OString& sLanguage , OString const & sPath ) { file->Extract(); @@ -189,7 +189,6 @@ bool HelpParser::MergeSingleFile( XMLFile* file , MergeDataFile* pMergeDataFile } file->Write(sPath); - return true; } /* ProcessHelp method: search for en-US entry and replace it with the current language*/ diff --git a/l10ntools/source/lngmerge.cxx b/l10ntools/source/lngmerge.cxx index f5215e4d14b2..39f98747e99c 100644 --- a/l10ntools/source/lngmerge.cxx +++ b/l10ntools/source/lngmerge.cxx @@ -79,7 +79,7 @@ LngParser::~LngParser() { } -bool LngParser::CreatePO( const OString &rPOFile ) +void LngParser::CreatePO( const OString &rPOFile ) { PoOfstream aPOStream( rPOFile, PoOfstream::APP ); if (!aPOStream.isOpen()) { @@ -109,7 +109,6 @@ bool LngParser::CreatePO( const OString &rPOFile ) Text.erase("x-comment"); } aPOStream.close(); - return true; } void LngParser::WritePO(PoOfstream &aPOStream, @@ -145,7 +144,7 @@ void LngParser::ReadLine(const OString &rLine_in, } } -bool LngParser::Merge( +void LngParser::Merge( const OString &rPOFile, const OString &rDestinationFile, const OString &rLanguage ) @@ -290,7 +289,6 @@ bool LngParser::Merge( aDestination << mvLines[i] << '\n'; aDestination.close(); - return true; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/l10ntools/source/xmlparse.cxx b/l10ntools/source/xmlparse.cxx index f8faf8538089..462c4d2e1ce9 100644 --- a/l10ntools/source/xmlparse.cxx +++ b/l10ntools/source/xmlparse.cxx @@ -164,7 +164,7 @@ void XMLFile::Write( OString const &aFilename ) s.close(); } -bool XMLFile::Write( ofstream &rStream , XMLNode *pCur ) +void XMLFile::Write( ofstream &rStream , XMLNode *pCur ) { if ( !pCur ) Write( rStream, this ); @@ -229,7 +229,6 @@ bool XMLFile::Write( ofstream &rStream , XMLNode *pCur ) break; } } - return true; } void XMLFile::Print( XMLNode *pCur, sal_uInt16 nLevel ) |