X-Git-Url: https://git.danieliu.xyz/?a=blobdiff_plain;f=src%2Fmarkdown.c;h=32e8c31aac00e9cfb6d6cf535b11e05452ea3926;hb=22055d604b1207680ded02d98715df5cafdf8648;hp=8471724a6df223ad66e07dac87058b3fd8efc0af;hpb=f6eba201ce1ec4118d501ff7afa547324143c9b9;p=smdp.git diff --git a/src/markdown.c b/src/markdown.c index 8471724..32e8c31 100644 --- a/src/markdown.c +++ b/src/markdown.c @@ -1,6 +1,6 @@ /* * An implementation of markdown objects. - * Copyright (C) 2014 Michael Goehler + * Copyright (C) 2015 Michael Goehler * * This file is part of mdp. * @@ -43,7 +43,7 @@ slide_t *new_slide() { slide_t *x = malloc(sizeof(slide_t)); x->line = NULL; x->prev = x->next = NULL; - x->lines = 0; + x->lines = x->stop = 0; return x; } @@ -81,8 +81,6 @@ void free_deck(deck_t *deck) { while (slide) { free_line(slide->line); next = slide->next; - if (slide == NULL) - return; free(slide); slide = next; }