diff options
context:
space:
mode:
Diffstat (limited to 'source/html.h')
-rw-r--r--source/html.h12
1 file changed, 8 insertions, 4 deletions
diff --git a/source/html.h b/source/html.h
index 410661b..46b445f 100644
--- a/source/html.h
+++ b/source/html.h
@@ -12,10 +12,9 @@
#include "cgit.h"
-// How much of a generated run to build before handing it to html_raw. Growing
-// past this gains nothing, since html_raw gathers what it is given into a
-// buffer of its own, and a run built whole would grow with the file it came
-// from, to many times the blob's size, which max-blob-size never measures.
+// How much of a generated run to build before handing it to html_raw. A run
+// built whole would grow with the file it came from, to many times the blob's
+// size, which max-blob-size never measures.
#define HTML_BATCH (64 * 1024)
extern void html_raw(const char *txt, size_t size);
@@ -28,6 +27,11 @@ extern void html(const char *txt);
extern void html_flush(void);
/*
+ * Drop whatever page output is still buffered. For the die path only.
+ */
+extern void html_discard(void);
+
+/*
* Collect page output into sb rather than writing it, until html_capture_end.
* A capture must not span a filter or anything else that writes to stdout
* directly, since that output would escape the capture.