[Libreoffice-commits] core.git: helpcompiler/source
Stephan Bergmann
sbergman at redhat.com
Tue Aug 23 10:18:04 UTC 2016
helpcompiler/source/HelpCompiler.cxx | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
New commits:
commit 2b4d13f135cd0e0b7000f1de658c35c873f533b3
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue Aug 23 12:17:35 2016 +0200
Reduce scope of variable
Change-Id: Ib3669c8946b431b845bcb217e7cf4a5f7a89177f
diff --git a/helpcompiler/source/HelpCompiler.cxx b/helpcompiler/source/HelpCompiler.cxx
index 4f391b6..67dbfcd 100644
--- a/helpcompiler/source/HelpCompiler.cxx
+++ b/helpcompiler/source/HelpCompiler.cxx
@@ -330,14 +330,12 @@ void myparser::traverse( xmlNodePtr parentNode )
xmlFree (branchxml);
xmlFree (idxml);
- std::string hid;
-
if (branch.compare(0, 3, "hid") == 0)
{
size_t index = branch.find('/');
if (index != std::string::npos)
{
- hid = branch.substr(1 + index);
+ auto hid = branch.substr(1 + index);
// one shall serve as a documentId
if (documentId.empty())
documentId = hid;
More information about the Libreoffice-commits
mailing list