summaryrefslogtreecommitdiff
path: root/lib/abuf.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/abuf.c')
-rw-r--r--lib/abuf.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/abuf.c b/lib/abuf.c
index 8156177c773..61adf7fc6b1 100644
--- a/lib/abuf.c
+++ b/lib/abuf.c
@@ -119,6 +119,12 @@ void abuf_init_set(struct abuf *abuf, void *data, size_t size)
abuf_set(abuf, data, size);
}
+void abuf_init_const(struct abuf *abuf, const void *data, size_t size)
+{
+ /* for now there is no flag indicating that the abuf data is constant */
+ abuf_init_set(abuf, (void *)data, size);
+}
+
void abuf_init_move(struct abuf *abuf, void *data, size_t size)
{
abuf_init_set(abuf, data, size);