From 4dd8e7c0ce5ecc7f65e33e60ad2f717b31de32ec Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Wed, 21 Jun 2017 22:43:57 +0200 Subject: Implement allocation buffers for internal use This commit adds fixed-size allocation buffers. The primary use case is in NSS modules, where dynamically sized data is stored in a fixed-size buffer provided by the caller. Other uses include a replacement of mempcpy cascades (which is safer due to the size checking inherent to allocation buffers). --- malloc/Versions | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'malloc/Versions') diff --git a/malloc/Versions b/malloc/Versions index 5b543069b3..2357cff3da 100644 --- a/malloc/Versions +++ b/malloc/Versions @@ -76,7 +76,6 @@ libc { __libc_scratch_buffer_grow_preserve; __libc_scratch_buffer_set_array_size; - # Internal name for reallocarray __libc_reallocarray; @@ -86,5 +85,12 @@ libc { __libc_dynarray_finalize; __libc_dynarray_resize; __libc_dynarray_resize_clear; + + # struct alloc_buffer support + __libc_alloc_buffer_alloc_array; + __libc_alloc_buffer_allocate; + __libc_alloc_buffer_copy_bytes; + __libc_alloc_buffer_copy_string; + __libc_alloc_buffer_create_failure; } } -- cgit v1.2.3