summaryrefslogtreecommitdiff
path: root/src/core/line-split.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/line-split.h')
-rw-r--r--src/core/line-split.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/core/line-split.h b/src/core/line-split.h
new file mode 100644
index 00000000..56d694c3
--- /dev/null
+++ b/src/core/line-split.h
@@ -0,0 +1,13 @@
+#ifndef __LINE_SPLIT_H
+#define __LINE_SPLIT_H
+
+typedef struct _LINEBUF_REC LINEBUF_REC;
+
+/* line-split `data'. Initially `*buffer' should contain NULL. */
+int line_split(const char *data, int len, char **output, LINEBUF_REC **buffer);
+void line_split_free(LINEBUF_REC *buffer);
+
+/* Return 1 if there is no data in the buffer */
+int line_split_is_empty(LINEBUF_REC *buffer);
+
+#endif