From: Francois-Xavier Le Bail Date: Mon, 17 Jan 2022 14:31:53 +0000 (+0100) Subject: Memory allocator: Update nd_add_alloc_list() to a static function X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/491a445974b4499be66034c9eccbcf4056f9c9ab Memory allocator: Update nd_add_alloc_list() to a static function --- diff --git a/netdissect-alloc.c b/netdissect-alloc.c index bbae56ee..c625d34e 100644 --- a/netdissect-alloc.c +++ b/netdissect-alloc.c @@ -21,12 +21,14 @@ #include #include "netdissect-alloc.h" +static void nd_add_alloc_list(netdissect_options *, nd_mem_chunk_t *); + /* * nd_free_all() is intended to be used after a packet printing */ /* Add a memory chunk in allocation linked list */ -void +static void nd_add_alloc_list(netdissect_options *ndo, nd_mem_chunk_t *chunkp) { if (ndo->ndo_last_mem_p == NULL) /* first memory allocation */ diff --git a/netdissect-alloc.h b/netdissect-alloc.h index aa28a368..862c900f 100644 --- a/netdissect-alloc.h +++ b/netdissect-alloc.h @@ -26,7 +26,6 @@ typedef struct nd_mem_chunk { /* variable size data */ } nd_mem_chunk_t; -void nd_add_alloc_list(netdissect_options *, nd_mem_chunk_t *); void * nd_malloc(netdissect_options *, size_t); void nd_free_all(netdissect_options *);