25RCSID(
"$Id: 7c23080f3bb85fed1da6574e3a327ff4b491671a $")
27#include "unlang_priv.h"
38 unlang = unlang->
next) {
80 unlang = unlang->
next) {
85 RDEBUG3(
"No catch section for %s",
93 if (!unlang)
goto not_caught;
unlang_action_t
Returned by unlang_op_t calls, determine the next action of the interpreter.
static unlang_action_t unlang_catch(rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
static unlang_action_t catch_skip_to_next(UNUSED rlm_rcode_t *p_result, UNUSED request_t *request, unlang_stack_frame_t *frame)
void unlang_catch_init(void)
unlang_action_t unlang_interpret_skip_to_catch(rlm_rcode_t *p_result, request_t *request, unlang_stack_frame_t *frame)
Skip ahead to a particular "catch" instruction.
Declarations for the "catch" keyword.
static unlang_catch_t const * unlang_generic_to_catch(unlang_t const *g)
Cast a generic structure to the catch keyword extension.
bool catching[RLM_MODULE_NUMCODES]
fr_table_num_sorted_t const mod_rcode_table[]
unlang_action_t unlang_interpret_push_children(UNUSED rlm_rcode_t *p_result, request_t *request, rlm_rcode_t default_rcode, bool do_next_sibling)
Push the children of the current frame onto a new frame onto the stack.
void unlang_register(int type, unlang_op_t *op)
Register an operation with the interpreter.
rlm_rcode_t
Return codes indicating the result of the module call.
#define fr_table_str_by_value(_table, _number, _def)
Convert an integer to a string.
unlang_t * next
Next node (executed on UNLANG_ACTION_EXECUTE_NEXT et al).
#define UNLANG_NEXT_SIBLING
@ UNLANG_TYPE_TRY
try / catch blocks
@ UNLANG_TYPE_CATCH
catch a previous try
static void frame_repeat(unlang_stack_frame_t *frame, unlang_process_t process)
Mark the current stack frame up for repeat, and set a new process function.
unlang_t const * instruction
The unlang node we're evaluating.
rlm_rcode_t result
The result from executing the instruction.
static unlang_action_t frame_set_next(unlang_stack_frame_t *frame, unlang_t *unlang)
@ UNLANG_OP_FLAG_DEBUG_BRACES
Print debug braces.
unlang_type_t type
The specialisation of this node.
A node in a graph of unlang_op_t (s) that we execute.
Our interpreter stack, as distinct from the C stack.