From: Arran Cudbard-Bell Date: Sun, 1 Jun 2025 01:40:29 +0000 (-0600) Subject: Fix arg order to unlang_subrequest_child_push X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0110207176d7b97cebb36d64d41457c0bbf24ac3;p=thirdparty%2Ffreeradius-server.git Fix arg order to unlang_subrequest_child_push --- diff --git a/src/lib/tls/session.c b/src/lib/tls/session.c index a9da0fb44bd..62906005b52 100644 --- a/src/lib/tls/session.c +++ b/src/lib/tls/session.c @@ -2010,7 +2010,7 @@ unlang_action_t fr_tls_new_session_push(request_t *request, fr_tls_conf_t const MEM(pair_prepend_request(&vp, attr_tls_packet_type) >= 0); vp->vp_uint32 = enum_tls_packet_type_new_session->vb_uint32; - if (unlang_subrequest_child_push(child, NULL, child->parent, true, UNLANG_SUB_FRAME) < 0) { + if (unlang_subrequest_child_push(NULL, child, child->parent, true, UNLANG_SUB_FRAME) < 0) { return UNLANG_ACTION_FAIL; } if (unlang_function_push(NULL, child, NULL, tls_new_session_result, NULL, 0, UNLANG_SUB_FRAME, NULL) < 0) return UNLANG_ACTION_FAIL; diff --git a/src/lib/tls/virtual_server.c b/src/lib/tls/virtual_server.c index 84f4aaabf6b..2cc0a806d00 100644 --- a/src/lib/tls/virtual_server.c +++ b/src/lib/tls/virtual_server.c @@ -61,7 +61,7 @@ unlang_action_t fr_tls_call_push(request_t *child, unlang_function_t resume, * Sets up a dispatch frame in the parent * and a result processing frame in the child. */ - if (unlang_subrequest_child_push(child, NULL, + if (unlang_subrequest_child_push(NULL, child, tls_session, true, UNLANG_SUB_FRAME) < 0) { return UNLANG_ACTION_FAIL; diff --git a/src/lib/unlang/call.c b/src/lib/unlang/call.c index e11fafe4784..3169b358a6f 100644 --- a/src/lib/unlang/call.c +++ b/src/lib/unlang/call.c @@ -135,7 +135,7 @@ static unlang_action_t unlang_call_frame_init(unlang_result_t *p_result, request frame_repeat(frame, unlang_call_children); } - if (virtual_server_push(request, gext->server_cs, UNLANG_SUB_FRAME) < 0) goto error; + if (virtual_server_push(NULL, request, gext->server_cs, UNLANG_SUB_FRAME) < 0) goto error; return UNLANG_ACTION_PUSHED_CHILD; } diff --git a/src/lib/unlang/subrequest.c b/src/lib/unlang/subrequest.c index 9409d4ae1ce..76940199050 100644 --- a/src/lib/unlang/subrequest.c +++ b/src/lib/unlang/subrequest.c @@ -425,8 +425,7 @@ unlang_action_t unlang_subrequest_child_run(UNUSED unlang_result_t *p_result, UN * - -1 on failure. */ -int unlang_subrequest_child_push(request_t *child, - unlang_result_t *p_result, void const *unique_session_ptr, bool free_child, bool top_frame) +int unlang_subrequest_child_push(unlang_result_t *p_result, request_t *child, void const *unique_session_ptr, bool free_child, bool top_frame) { unlang_child_request_t *cr; unlang_stack_frame_t *frame; diff --git a/src/lib/unlang/subrequest.h b/src/lib/unlang/subrequest.h index ad65d086e5d..0c671b4630e 100644 --- a/src/lib/unlang/subrequest.h +++ b/src/lib/unlang/subrequest.h @@ -43,8 +43,8 @@ request_t *unlang_subrequest_alloc(request_t *parent, fr_dict_t const *namespace void unlang_subrequest_detach_and_free(request_t **child); -int unlang_subrequest_child_push(request_t *child, - unlang_result_t *p_result, void const *unique_session_ptr, bool free_child, bool top_frame); +int unlang_subrequest_child_push(unlang_result_t *p_result, request_t *child, + void const *unique_session_ptr, bool free_child, bool top_frame); int unlang_subrequest_child_push_and_detach(request_t *child); diff --git a/src/modules/rlm_eap/rlm_eap.c b/src/modules/rlm_eap/rlm_eap.c index 30a89a1e0c2..1476bd0f57e 100644 --- a/src/modules/rlm_eap/rlm_eap.c +++ b/src/modules/rlm_eap/rlm_eap.c @@ -826,7 +826,7 @@ static unlang_action_t eap_method_select(rlm_rcode_t *p_result, module_ctx_t con * This must be done before pushing frames onto * the child's stack. */ - if (unlang_subrequest_child_push(eap_session->subrequest, &eap_session->submodule_result, + if (unlang_subrequest_child_push(&eap_session->submodule_result, eap_session->subrequest, eap_session, false, UNLANG_SUB_FRAME) < 0) { child_fail: