Wireshark 4.7.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
wmem_allocator.h
Go to the documentation of this file.
1
13#ifndef __WMEM_ALLOCATOR_H__
14#define __WMEM_ALLOCATOR_H__
15
16#include <glib.h>
17#include <string.h>
18
19#ifdef __cplusplus
20extern "C" {
21#endif /* __cplusplus */
22
24
35 /* Consumer functions */
36 void *(*walloc)(void *private_data, const size_t size);
37 void (*wfree)(void *private_data, void *ptr);
38 void *(*wrealloc)(void *private_data, void *ptr, const size_t size);
40 /* Producer/Manager functions */
41 void (*free_all)(void *private_data);
42 void (*gc)(void *private_data);
43 void (*cleanup)(void *private_data);
45 /* Callback List */
48 /* Implementation details */
51 bool in_scope;
52};
53
54#ifdef __cplusplus
55}
56#endif /* __cplusplus */
57
58#endif /* __WMEM_ALLOCATOR_H__ */
59
60/*
61 * Editor modelines - https://www.wireshark.org/tools/modelines.html
62 *
63 * Local variables:
64 * c-basic-offset: 4
65 * tab-width: 8
66 * indent-tabs-mode: nil
67 * End:
68 *
69 * vi: set shiftwidth=4 tabstop=8 expandtab:
70 * :indentSize=4:tabSize=8:noTabs=true:
71 */
_wmem_allocator_type_t
Definition wmem_core.h:47
Internal memory allocator interface used by the wmem subsystem.
Definition wmem_allocator.h:34
enum _wmem_allocator_type_t type
Definition wmem_allocator.h:50
void(* wfree)(void *private_data, void *ptr)
Definition wmem_allocator.h:37
struct _wmem_user_cb_container_t * callbacks
Definition wmem_allocator.h:46
void(* cleanup)(void *private_data)
Definition wmem_allocator.h:43
void(* gc)(void *private_data)
Definition wmem_allocator.h:42
bool in_scope
Definition wmem_allocator.h:51
void(* free_all)(void *private_data)
Definition wmem_allocator.h:41
void * private_data
Definition wmem_allocator.h:49
Definition wmem_user_cb.c:18