From: Thibaut Cuvelier Date: Thu, 7 Oct 2021 00:34:07 +0000 (+0200) Subject: DocBook: add assertion to help debugging. X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=48a507694ea44d511da55917af64fa5dedabff37;p=features.git DocBook: add assertion to help debugging. --- diff --git a/src/output_docbook.cpp b/src/output_docbook.cpp index 50b66fbac0..e234d9d652 100644 --- a/src/output_docbook.cpp +++ b/src/output_docbook.cpp @@ -754,6 +754,8 @@ DocBookDocumentSectioning hasDocumentSectioning(ParagraphList const ¶graphs, bool documentHasSections = false; while (bpit < epit) { + LASSERT(bpit < paragraphs.size(), return make_tuple(documentHasSections, bpit)); + Layout const &style = paragraphs[bpit].layout(); documentHasSections |= isLayoutSectioningOrSimilar(style);