summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2014-11-16 10:45:50 -0800
committerJohn MacFarlane <fiddlosopher@gmail.com>2014-11-16 10:45:50 -0800
commit5a26ca5cf9481289ad77d6049b55c48feea7cc38 (patch)
tree561595c5de9009425a168a39d9f4f3060b82183d /src/main.c
parentb7f6e3f775705029df262aa313a0cd17ee3073cb (diff)
cmark_render_html now just returns a regular C string.
This way, we don't have to expose buffer.h; it is just used internally.
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/main.c b/src/main.c
index 20a708b..04b5376 100644
--- a/src/main.c
+++ b/src/main.c
@@ -3,7 +3,6 @@
#include <string.h>
#include <errno.h>
#include "cmark.h"
-#include "buffer.h"
#include "debug.h"
#include "bench.h"
@@ -17,14 +16,10 @@ void print_usage()
static void print_document(node_block *document, bool ast)
{
- strbuf html = GH_BUF_INIT;
-
if (ast) {
cmark_debug_print(document);
} else {
- cmark_render_html(&html, document);
- printf("%s", html.ptr);
- strbuf_free(&html);
+ printf("%s", cmark_render_html(document));
}
}