Fix: Check for HTML block continuation after checking for blockquote mark.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
diff --git a/md4c/md4c.c b/md4c/md4c.c
index 7a11ac3..224c416 100644
--- a/md4c/md4c.c
+++ b/md4c/md4c.c
@@ -1540,6 +1540,16 @@ redo_indentation_after_blockquote_mark:
goto done;
}
+ /* Check blockquote mark. */
+ if(off < ctx->size && CH(off) == _T('>')) {
+ off++;
+ if(off < ctx->size && CH(off) == _T(' '))
+ off++;
+ line->quote_level++;
+ line->indent = 0;
+ goto redo_indentation_after_blockquote_mark;
+ }
+
/* Check whether we are HTML block continuation. */
if(pivot_line->type == MD_LINE_HTML && ctx->html_block_type > 0) {
if(md_is_html_block_end_condition(ctx, off) == ctx->html_block_type) {
@@ -1551,16 +1561,6 @@ redo_indentation_after_blockquote_mark:
goto done;
}
- /* Check blockquote mark. */
- if(off < ctx->size && CH(off) == _T('>')) {
- off++;
- if(off < ctx->size && CH(off) == _T(' '))
- off++;
- line->quote_level++;
- line->indent = 0;
- goto redo_indentation_after_blockquote_mark;
- }
-
/* Check whether we are blank line.
* Note blank lines after indented code are treated as part of that block.
* If they are at the end of the block, it is discarded by caller.