aboutsummaryrefslogtreecommitdiff
path: root/buffer.h
diff options
context:
space:
mode:
authorMarc André Tanner <mat@brain-dump.org>2016-04-01 13:14:20 +0200
committerMarc André Tanner <mat@brain-dump.org>2016-04-03 13:13:51 +0200
commita841dce73e1ad510946caf8747dee44e1f46b254 (patch)
treea00b5a4f2d347c3d7022526fa45e940ab5308f6b /buffer.h
parent4ad51b6fe4c25e3ed034956f41482428b5ed315e (diff)
downloadvis-a841dce73e1ad510946caf8747dee44e1f46b254.tar.gz
vis-a841dce73e1ad510946caf8747dee44e1f46b254.tar.xz
buffer: add buffer_length utility function
Diffstat (limited to 'buffer.h')
-rw-r--r--buffer.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/buffer.h b/buffer.h
index 7e3c342..fcdad47 100644
--- a/buffer.h
+++ b/buffer.h
@@ -40,5 +40,7 @@ bool buffer_prepend(Buffer*, const void *data, size_t len);
bool buffer_prepend0(Buffer*, const char *data);
/* return length of a buffer without trailing NUL byte */
size_t buffer_length0(Buffer*);
+/* return length of a buffer including possible NUL byte */
+size_t buffer_length(Buffer*);
#endif