aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/stack.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/stack.h b/src/stack.h
index d2445984..122b3b14 100644
--- a/src/stack.h
+++ b/src/stack.h
@@ -35,7 +35,7 @@ static inline SerdStack
serd_stack_new(size_t size)
{
SerdStack stack;
- stack.buf = (char*)malloc(size);
+ stack.buf = (char*)calloc(1, size);
stack.buf_size = size;
stack.size = SERD_STACK_BOTTOM;
return stack;