]> git.lyx.org Git - features.git/commitdiff
Fix wrong label found by cppcheck
authorGeorg Baum <baum@lyx.org>
Sun, 20 Sep 2015 18:32:45 +0000 (20:32 +0200)
committerGeorg Baum <baum@lyx.org>
Sun, 20 Sep 2015 18:32:45 +0000 (20:32 +0200)
It was not intended to ignore the return value of expandParagraphLabel().

src/Paragraph.cpp

index 84e609bb605c642779e9d799e385a5252a5b08e8..5bbc16aaed0bb297b5ad7d2d42ffe76bb29af505 100644 (file)
@@ -1997,7 +1997,7 @@ docstring Paragraph::expandParagraphLabel(Layout const & layout,
                        docstring parent(fmt, i + 1, j - i - 1);
                        docstring label = from_ascii("??");
                        if (tclass.hasLayout(parent))
-                               docstring label = expandParagraphLabel(tclass[parent], bparams,
+                               label = expandParagraphLabel(tclass[parent], bparams,
                                                      process_appendix);
                        fmt = docstring(fmt, 0, i) + label
                                + docstring(fmt, j + 1, docstring::npos);