summaryrefslogtreecommitdiffstats
path: root/buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'buffer.c')
-rw-r--r--buffer.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/buffer.c b/buffer.c
index 03ff8fc..08f0656 100644
--- a/buffer.c
+++ b/buffer.c
@@ -54,6 +54,7 @@ alloc_buf_gc (size_t size, struct gc_arena *gc)
#endif
{
struct buffer buf;
+ ASSERT (size <= BUF_MAX);
buf.capacity = (int)size;
buf.offset = 0;
buf.len = 0;