Skip to content

Commit 45c4cdc

Browse files
committed
issue #10950 ASSERT(0) in docnode.cpp
1 parent c5e06a2 commit 45c4cdc

File tree

3 files changed

+22
-11
lines changed

3 files changed

+22
-11
lines changed

src/docnode.cpp

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5089,17 +5089,24 @@ int DocPara::handleHtmlEndTag(const QCString &tagName)
50895089
}
50905090
break;
50915091
case HTML_DETAILS:
5092-
retval=RetVal_EndHtmlDetails;
5092+
if (!insideDetails(thisVariant()))
5093+
{
5094+
warn_doc_error(parser()->context.fileName,parser()->tokenizer.getLineNr(),"found </details> tag without matching <details>");
5095+
}
5096+
else
5097+
{
5098+
retval=RetVal_EndHtmlDetails;
5099+
}
50935100
break;
50945101
case HTML_BLOCKQUOTE:
5095-
//if (!insideBlockQuote(thisVariant()))
5096-
//{
5097-
// warn_doc_error(parser()->context.fileName,parser()->tokenizer.getLineNr(),"found </blockquote> tag without matching <blockquote>");
5098-
//}
5099-
//else
5100-
//{
5101-
retval=RetVal_EndBlockQuote;
5102-
//}
5102+
if (!insideBlockQuote(thisVariant()))
5103+
{
5104+
warn_doc_error(parser()->context.fileName,parser()->tokenizer.getLineNr(),"found </blockquote> tag without matching <blockquote>");
5105+
}
5106+
else
5107+
{
5108+
retval=RetVal_EndBlockQuote;
5109+
}
51035110
break;
51045111
case HTML_BOLD:
51055112
parser()->handleStyleLeave(thisVariant(),children(),DocStyleChange::Bold,tagName);

src/markdown.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2788,7 +2788,11 @@ size_t Markdown::Private::writeBlockQuote(std::string_view data)
27882788
out += "</blockquote>";
27892789
}
27902790
}
2791-
if (level==0) break; // end of quote block
2791+
if (level==0)
2792+
{
2793+
curLevel=0;
2794+
break; // end of quote block
2795+
}
27922796
// copy line without quotation marks
27932797
if (curLevel!=0 || !isGitHubAlert)
27942798
{

src/trace.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
// Since some modules produce a huge amount of tracing we disable those traces by default.
2828
// Set of or more of the following to 1 to enable the relevant tracing
2929
#define ENABLE_SYMBOLRESOLVER_TRACING 0
30-
#define ENABLE_MARKDOWN_TRACING 1
30+
#define ENABLE_MARKDOWN_TRACING 0
3131
#define ENABLE_DOCPARSER_TRACING 0
3232

3333

0 commit comments

Comments
 (0)