]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Add a note on memory allocation
authorMatthijs Mekking <matthijs@isc.org>
Tue, 4 Feb 2020 10:00:58 +0000 (11:00 +0100)
committerMatthijs Mekking <matthijs@isc.org>
Wed, 5 Feb 2020 08:08:35 +0000 (09:08 +0100)
isc__memalloc_t must deal with memory allocation failure
and must never return NULL.

(cherry picked from commit b8be29fee61c46170dc087ee72b88a84ef9f8d21)

lib/isc/include/isc/mem.h

index 6f61c17505ee6a606394a7b6ef363e7b905d0b63..3cdc9376d9eff7e6d13eee83a16803fbb9e82217 100644 (file)
@@ -30,6 +30,11 @@ ISC_LANG_BEGINDECLS
 #define ISC_MEM_HIWATER 1
 typedef void (*isc_mem_water_t)(void *, int);
 
+/*%
+ * Memory allocation and free function definitions.
+ * isc_memalloc_t must deal with memory allocation failure
+ * and must never return NULL.
+ */
 typedef void * (*isc_memalloc_t)(void *, size_t);
 typedef void (*isc_memfree_t)(void *, void *);