path: root/include/utils.h
diff options
authorOleksandr Natalenko <>2017-01-02 20:54:08 +0100
committerFlorian Westphal <>2017-01-03 02:42:14 +0100
commit87efdaf0a7a804cda24749246b26772bbdcaef5e (patch)
treeb76853ba014746b359b79371852f1d36115e586e /include/utils.h
parentf2fb89ebb622b49186dc9c76f9fcb76f57c35624 (diff)
utils: provide array allocation wrapper
This will be used for allocating memory for arrays in heap instead of keeping them on stack. Signed-off-by: Oleksandr Natalenko <> Signed-off-by: Florian Westphal <>
Diffstat (limited to 'include/utils.h')
1 files changed, 1 insertions, 0 deletions
diff --git a/include/utils.h b/include/utils.h
index bb58ba42..3199388a 100644
--- a/include/utils.h
+++ b/include/utils.h
@@ -138,6 +138,7 @@ extern void __memory_allocation_error(const char *filename, uint32_t line) __nor
extern void xfree(const void *ptr);
extern void *xmalloc(size_t size);
+extern void *xmalloc_array(size_t nmemb, size_t size);
extern void *xrealloc(void *ptr, size_t size);
extern void *xzalloc(size_t size);
extern char *xstrdup(const char *s);