md4c

C Markdown parser. Fast. SAX-like interface. Compliant to CommonMark specification.
git clone https://noulin.net/git/md4c.git
Log | Files | Refs | README | LICENSE

commit 9b693331976957aa856a8c5a510b4d3e3ae3bfb3
parent 5980578054ff655c86c8898d75f00d8da73df253
Author: Martin Mitas <mity@morous.org>
Date:   Sat,  8 Oct 2016 22:59:12 +0200

Fix: Fence code block indetation base is defined by indentation of opening code fence.

Diffstat:
Mmd4c/md4c.c | 6++++++
1 file changed, 6 insertions(+), 0 deletions(-)

diff --git a/md4c/md4c.c b/md4c/md4c.c @@ -1530,6 +1530,12 @@ redo_indentation_after_blockquote_mark: } } + /* Change indentation accordingly to the initial code fence. */ + if(line->indent > pivot_line->indent) + line->indent -= pivot_line->indent; + else + line->indent = 0; + line->type = MD_LINE_FENCEDCODE; goto done; }