diff --git a/stagit.c b/stagit.c
@@ -14,6 +14,7 @@
#include <unistd.h>
#include <git2.h>
+#include <cmark_export.h>
#include "compat.h"
@@ -84,7 +85,8 @@ static const char *cachefile;
void write_markdown_readme(FILE *file, git_blob *readme)
{
char *markdown = git_blob_rawcontent(readme);
- char *html = cmark_markdown_to_html(markdown, strlen(markdown), 0);
+ char *html = cmark_markdown_to_html(markdown,
+ strlen(markdown), CMARK_OPT_SAFE);
fprintf(file, "%s", html);
free(html);