]> granicus.if.org Git - multimarkdown/commitdiff
FIXED: Fix bug in HR parsing
authorFletcher T. Penney <fletcher@fletcherpenney.net>
Sat, 18 Mar 2017 14:09:16 +0000 (10:09 -0400)
committerFletcher T. Penney <fletcher@fletcherpenney.net>
Sat, 18 Mar 2017 14:09:16 +0000 (10:09 -0400)
Sources/libMultiMarkdown/mmd.c

index ff00331697675528b975a3c327cdff66a6a3baf6..76cfbbbba5a64a0f4387f406a0ca03b94620f33e 100644 (file)
@@ -482,7 +482,8 @@ void mmd_assign_line_type(mmd_engine * e, token * line) {
                                        case DASH_M:
                                                if (t->type == line->child->type) {
                                                        t = t->next;
-                                                       temp_short += t->len;
+                                                       if (t)
+                                                               temp_short += t->len;
                                                } else {
                                                        temp_short = 0;
                                                        t = NULL;