summaryrefslogtreecommitdiffstats
path: root/src/lib/ostream-hash.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/ostream-hash.h')
-rw-r--r--src/lib/ostream-hash.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/lib/ostream-hash.h b/src/lib/ostream-hash.h
new file mode 100644
index 0000000..7fb4b6d
--- /dev/null
+++ b/src/lib/ostream-hash.h
@@ -0,0 +1,12 @@
+#ifndef OSTREAM_HASH_H
+#define OSTREAM_HASH_H
+
+struct hash_method;
+
+/* hash_context must be allocated and initialized by caller. This ostream will
+ simply call method->loop() for all the data going through the ostream. */
+struct ostream *
+o_stream_create_hash(struct ostream *output, const struct hash_method *method,
+ void *hash_context);
+
+#endif