29 RCSIDH(module_ctx_h,
"$Id: aa05f838015e12e458fef82fe4840662891057b2 $")
31 #include <freeradius-devel/server/dl_module.h>
32 #include <freeradius-devel/util/event.h>
77 nmctx->
inst = mctx->inst;
106 memcpy(nmctx, mctx,
sizeof(*nmctx));
123 #define MODULE_CTX(_dl_inst, _thread, _env_data, _rctx) &(module_ctx_t){ .inst = _dl_inst, .thread = _thread, .env_data = _env_data, .rctx = _rctx }
133 #define MODULE_CTX_FROM_INST(_mctx) &(module_ctx_t){ .inst = (_mctx)->inst }
143 #define MODULE_CTX_FROM_THREAD_INST(_mctx) &(module_ctx_t){ .inst = (_mctx)->inst, .thread = (_mctx)->thread, .env_data = (_mctx)->env_data }
153 #define MODULE_INST_CTX(_dl_inst) &(module_inst_ctx_t){ .inst = _dl_inst }
165 #define MODULE_THREAD_INST_CTX(_dl_inst, _thread, _el) &(module_thread_inst_ctx_t){ .inst = _dl_inst, .thread = _thread, .el = _el }
173 #define MODULE_THREAD_INST_CTX_FROM_INST_CTX(_mctx) &(module_ctx_t){ .inst = (_mctx)->inst }
Stores all information relating to an event list.
void * env_data
Per call environment data.
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.
dl_module_inst_t const * inst
Dynamic loader API handle for the module.
void * thread
Thread instance data.
dl_module_inst_t const * inst
Dynamic loader API handle for the module.
dl_module_inst_t const * inst
Dynamic loader API handle for the module.
Temporary structure to hold arguments for module calls.
Temporary structure to hold arguments for instantiation calls.
Temporary structure to hold arguments for thread_instantiation calls.