29 RCSIDH(module_ctx_h,
"$Id: 1db004302cc4620d69a8ece0a5fdbb22f1ca6a86 $")
31 #include <freeradius-devel/util/event.h>
111 memcpy(nmctx, mctx,
sizeof(*nmctx));
128 #define MODULE_CTX(_mi, _thread, _env_data, _rctx) &(module_ctx_t){ .mi = _mi, .thread = _thread, .env_data = _env_data, .rctx = _rctx }
138 #define MODULE_CTX_FROM_INST(_mctx) &(module_ctx_t){ .mi = (_mctx)->mi }
148 #define MODULE_CTX_FROM_THREAD_INST(_mctx) &(module_ctx_t){ .mi = (_mctx)->mi, .thread = (_mctx)->thread, .env_data = (_mctx)->env_data }
158 #define MODULE_INST_CTX(_mi) &(module_inst_ctx_t){ .mi = _mi }
164 #define MODULE_DETACH_CTX(_mi) &(module_detach_ctx_t){ .mi = _mi }
176 #define MODULE_THREAD_INST_CTX(_mi, _thread, _el) &(module_thread_inst_ctx_t){ .mi = _mi, .thread = _thread, .el = _el }
184 #define MODULE_THREAD_INST_CTX_FROM_INST_CTX(_mctx) &(module_ctx_t){ .mi = (_mctx)->mi }
Stores all information relating to an event list.
void * env_data
Per call environment data.
module_instance_t const * mi
Instance of the module being instantiated.
void * thread
Thread specific instance data.
static module_ctx_t * module_ctx_from_inst(TALLOC_CTX *ctx, module_inst_ctx_t const *mctx)
Allocate a module calling ctx on the heap based on an instance ctx.
static module_ctx_t * module_ctx_from_thread_inst(TALLOC_CTX *ctx, module_thread_inst_ctx_t const *mctx)
Allocate a module calling ctx on the heap based on an instance ctx.
void * rctx
Resume ctx that a module previously set.
fr_event_list_t * el
Event list to register any IO handlers and timers against.
static module_ctx_t * module_ctx_dup(TALLOC_CTX *ctx, module_ctx_t const *mctx)
Duplicate a stack based module_ctx_t on the heap.
module_instance_t * mi
Module instance to detach.
void * thread
Thread instance data.
module_instance_t const * mi
Instance of the module being instantiated.
module_instance_t * mi
Instance of the module being instantiated.
Temporary structure to hold arguments for module calls.
Temporary structure to hold arguments for detach calls.
Temporary structure to hold arguments for instantiation calls.
Temporary structure to hold arguments for thread_instantiation calls.