25RCSID(
"$Id: 83165a2ff6bbd6f255532b77af0a7a5e69b697d9 $")
27#include "unlang_priv.h"
54 cf_log_err(cs,
"'try' sections cannot be empty");
61 cf_log_err(cs,
"Unexpected argument to 'try' section");
70 cf_log_err(cs,
"'try' sections must be followed by a 'catch'");
95 .unlang_name =
"unlang_try_t",
unlang_action_t
Returned by unlang_op_t calls, determine the next action of the interpreter.
unlang_action_t unlang_interpret_skip_to_catch(UNUSED unlang_result_t *p_result, request_t *request, unlang_stack_frame_t *frame)
Skip ahead to a particular "catch" instruction.
Declarations for the "catch" keyword.
Common header for all CONF_* types.
A section grouping multiple CONF_PAIR.
char const * cf_section_name2(CONF_SECTION const *cs)
Return the second identifier of a CONF_SECTION.
char const * cf_section_name1(CONF_SECTION const *cs)
Return the second identifier of a CONF_SECTION.
CONF_SECTION * cf_item_to_section(CONF_ITEM const *ci)
Cast a CONF_ITEM to a CONF_SECTION.
bool cf_item_is_data(CONF_ITEM const *ci)
Determine if CONF_ITEM is CONF_DATA.
bool cf_item_is_section(CONF_ITEM const *ci)
Determine if CONF_ITEM is a CONF_SECTION.
#define cf_log_err(_cf, _fmt,...)
#define cf_item_next(_parent, _curr)
unlang_t * unlang_compile_children(unlang_group_t *g, unlang_compile_ctx_t *unlang_ctx_in)
unlang_group_t * unlang_group_allocate(unlang_t *parent, CONF_SECTION *cs, unlang_type_t type)
unlang_action_t unlang_interpret_push_children(unlang_result_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.
static TALLOC_CTX * unlang_ctx
void unlang_register(unlang_op_t *op)
Register an operation with the interpreter.
@ RLM_MODULE_NOT_SET
Error resolving rcode (should not be returned by modules).
static unlang_action_t unlang_try(UNUSED unlang_result_t *p_result, request_t *request, unlang_stack_frame_t *frame)
static unlang_t * unlang_compile_try(unlang_t *parent, unlang_compile_ctx_t *unlang_ctx, CONF_ITEM const *ci)
void unlang_try_init(void)
Declaration for unlang try.
#define UNLANG_NEXT_SIBLING
char const * debug_name
Printed in log messages when the node is executed.
static unlang_t * unlang_group_to_generic(unlang_group_t const *p)
char const * name
Unknown...
@ UNLANG_TYPE_TRY
try / catch blocks
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_OP_FLAG_DEBUG_BRACES
Print debug braces.
Generic representation of a grouping.
A node in a graph of unlang_op_t (s) that we execute.
Our interpreter stack, as distinct from the C stack.
#define DOC_KEYWORD_REF(_x)