summaryrefslogtreecommitdiff
path: root/src/cmark.h
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2016-04-26 21:39:51 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2016-04-26 21:41:16 -0700
commit42ea18599f66a3af00887280770aa9479c453b21 (patch)
tree60eb8cf89a92b3ea7e11758a93dde00320268bc4 /src/cmark.h
parent2aa269f8dcbc0b091a92f89045ff7f6b16ffa09b (diff)
Clarify that it's the caller's responsibility to free the buffer...
returned by cmark_render_html etc. Closes #124.
Diffstat (limited to 'src/cmark.h')
-rw-r--r--src/cmark.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/cmark.h b/src/cmark.h
index 40aa465..2f4e603 100644
--- a/src/cmark.h
+++ b/src/cmark.h
@@ -465,28 +465,33 @@ cmark_node *cmark_parse_file(FILE *f, int options);
* ## Rendering
*/
-/** Render a 'node' tree as XML.
+/** Render a 'node' tree as XML. It is the caller's responsibility
+ * to free the returned buffer.
*/
CMARK_EXPORT
char *cmark_render_xml(cmark_node *root, int options);
/** Render a 'node' tree as an HTML fragment. It is up to the user
- * to add an appropriate header and footer.
+ * to add an appropriate header and footer. It is the caller's
+ * responsibility to free the returned buffer.
*/
CMARK_EXPORT
char *cmark_render_html(cmark_node *root, int options);
/** Render a 'node' tree as a groff man page, without the header.
+ * It is the caller's responsibility to free the returned buffer.
*/
CMARK_EXPORT
char *cmark_render_man(cmark_node *root, int options, int width);
/** Render a 'node' tree as a commonmark document.
+ * It is the caller's responsibility to free the returned buffer.
*/
CMARK_EXPORT
char *cmark_render_commonmark(cmark_node *root, int options, int width);
/** Render a 'node' tree as a LaTeX document.
+ * It is the caller's responsibility to free the returned buffer.
*/
CMARK_EXPORT
char *cmark_render_latex(cmark_node *root, int options, int width);