diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-23 16:05:57 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-06-25 17:19:48 +0200 |
commit | 93d42c1b23721120fd2b61ee0b8842a14fd9b6b8 (patch) | |
tree | 5a2c4108ad65f7171a6c9bbf87199c874693a703 /l10ntools | |
parent | a006f60b6ae22db6acb57d06167a3c6fd8bc6f1b (diff) |
loplugin:oncevar in l10ntools..mysqlc
Change-Id: Ifd4826f8ba4e10f2e012172fa693794d68bb6b4d
Reviewed-on: https://gerrit.libreoffice.org/39188
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'l10ntools')
-rw-r--r-- | l10ntools/source/cfgmerge.cxx | 3 | ||||
-rw-r--r-- | l10ntools/source/export.cxx | 6 | ||||
-rw-r--r-- | l10ntools/source/lngmerge.cxx | 11 |
3 files changed, 6 insertions, 14 deletions
diff --git a/l10ntools/source/cfgmerge.cxx b/l10ntools/source/cfgmerge.cxx index d8ec518c1a3a..e7596e85d0fc 100644 --- a/l10ntools/source/cfgmerge.cxx +++ b/l10ntools/source/cfgmerge.cxx @@ -262,9 +262,8 @@ void CfgParser::ExecuteAnalyzedToken( int nToken, char *pToken ) else { OString sError( "Misplaced close tag: " ); - OString sInFile(" in file "); sError += sToken; - sError += sInFile; + sError += " in file "; sError += global::inputPathname; yyerror(sError.getStr()); std::exit(EXIT_FAILURE); diff --git a/l10ntools/source/export.cxx b/l10ntools/source/export.cxx index b4995ca04fb5..a3f98ef3f2ac 100644 --- a/l10ntools/source/export.cxx +++ b/l10ntools/source/export.cxx @@ -152,8 +152,7 @@ bool ResData::SetId( const OString& rId, IdLevel nLevel ) if ( bChild && bChildWithText ) { - OString sError("ResId after child definition"); - yyerror(sError.getStr()); + yyerror("ResId after child definition"); SetError(); } @@ -830,9 +829,8 @@ OString Export::FullId() } if (sFull.getLength() > 255) { - OString sError("GroupId > 255 chars"); printf("GroupID = %s\n", sFull.getStr()); - yyerror(sError.getStr()); + yyerror("GroupId > 255 chars"); } return sFull.makeStringAndClear(); diff --git a/l10ntools/source/lngmerge.cxx b/l10ntools/source/lngmerge.cxx index 540110f99822..0537dd8ebb44 100644 --- a/l10ntools/source/lngmerge.cxx +++ b/l10ntools/source/lngmerge.cxx @@ -122,14 +122,9 @@ void LngParser::WritePO(PoOfstream &aPOStream, OStringHashMap &rText_inout, const OString &rActFileName, const OString &rID) { - - bool bExport = true; - if ( bExport ) - { - common::writePoEntry( - "Ulfex", aPOStream, rActFileName, "LngText", - rID, OString(), rText_inout.count("x-comment") ? rText_inout["x-comment"] : OString(), rText_inout["en-US"]); - } + common::writePoEntry( + "Ulfex", aPOStream, rActFileName, "LngText", + rID, OString(), rText_inout.count("x-comment") ? rText_inout["x-comment"] : OString(), rText_inout["en-US"]); } bool LngParser::isNextGroup(OString &sGroup_out, const OString &sLine_in) |