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 d6f40880583e7300fe131816e60b9d540e5f383d
parent 9af285a67eefaf9b22b8e142cd71a900efbcd566
Author: Martin Mitas <mity@morous.org>
Date:   Tue, 11 Oct 2016 13:22:44 +0200

Fix branching on initialized variable.

(Caught with Valgrind.)

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

diff --git a/md4c/md4c.c b/md4c/md4c.c @@ -1038,11 +1038,9 @@ md_collect_marks(MD_CTX* ctx, const MD_LINE* lines, int n_lines) } } - /* Add a dummy mark at the end of processed block to simplify + /* Add a dummy mark after the end of processed block to simplify * md_process_inlines(). */ - PUSH_MARK_(); - mark->beg = lines[n_lines-1].end + 1; - mark->flags = MD_MARK_RESOLVED; + PUSH_MARK(127, ctx->size+1, ctx->size+1, MD_MARK_RESOLVED); abort: return ret;