correcting some minor issues - smu - smu - simple markup (Markdown) processor (fork, fixes + features)
 (HTM) git clone git://git.codemadness.org/smu
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit cb129c84baf96c17f24440a6a23255d8aadfd0c5
 (DIR) parent d86557e66a684ce2bd3b16dab9a5e16d47c9df89
 (HTM) Author: gottox@rootkit.lan <gottox@rootkit.lan>
       Date:   Thu, 27 Dec 2007 19:22:34 +0100
       
       correcting some minor issues
       
       Diffstat:
         M cmarkdown.c                         |       6 ++++--
         M config.mk                           |       2 +-
       
       2 files changed, 5 insertions(+), 3 deletions(-)
       ---
 (DIR) diff --git a/cmarkdown.c b/cmarkdown.c
       @@ -130,6 +130,7 @@ doamp(const char *begin, const char *end, int newblock) {
                fputs("&amp;",stdout);
                return 1;
        }
       +
        unsigned int
        dohtml(const char *begin, const char *end, int newblock) {
                const char *p, *tag, *tagend;
       @@ -156,6 +157,7 @@ dohtml(const char *begin, const char *end, int newblock) {
                }
                return 0;
        }
       +
        unsigned int
        dolineprefix(const char *begin, const char *end, int newblock) {
                unsigned int i, j, l;
       @@ -164,7 +166,7 @@ dolineprefix(const char *begin, const char *end, int newblock) {
        
                if(!newblock)
                        return 0;
       -                p = begin;
       +        p = begin;
                for(i = 0; i < LENGTH(lineprefix); i++) {
                        l = strlen(lineprefix[i].search);
                        if(end - p < l)
       @@ -174,7 +176,7 @@ dolineprefix(const char *begin, const char *end, int newblock) {
                        if(!(buffer = malloc(BUFFERSIZE)))
                                eprint("Malloc failed.");
                        buffer[0] = '\0';
       -                puts(lineprefix[i].before);
       +                fputs(lineprefix[i].before,stdout);
                        for(j = 0, p += l; p != end; p++, j++) {
                                ADDC(buffer,j) = *p;
                                if(*p == '\n') {
 (DIR) diff --git a/config.mk b/config.mk
       @@ -10,7 +10,7 @@ INCS = -I. -I/usr/include
        LIBS = -L/usr/lib
        
        # flags
       -CFLAGS = -Os -Wall -Werror ${INCS} -DVERSION=\"${VERSION}\"
       +CFLAGS = -Os -Wall -Werror -ansi ${INCS} -DVERSION=\"${VERSION}\"
        LDFLAGS = ${LIBS}
        
        # compiler