]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Get the listen section from the parent module
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Tue, 14 May 2024 00:29:23 +0000 (18:29 -0600)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Tue, 14 May 2024 00:29:23 +0000 (18:29 -0600)
src/listen/bfd/proto_bfd_udp.c
src/listen/dhcpv4/proto_dhcpv4_udp.c
src/listen/dhcpv6/proto_dhcpv6_udp.c
src/listen/radius/proto_radius_udp.c
src/listen/tacacs/proto_tacacs_tcp.c
src/listen/vmps/proto_vmps_udp.c

index 6f6748b4fc2303ad152b84d3f613b772bde7db49..2e40eb6b90eedd466c1025ff99b87ac7cf054f8c 100644 (file)
@@ -420,7 +420,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);
index 0af615ecf2929db6d0a127258e7f75bcb0d56b7a..8492b065bbfea3b6560fcd143c0ebb16fa8cd225 100644 (file)
@@ -763,7 +763,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);
index 2f103e8746b8ddb63f7611a27b8f804fa669c8e5..3535e3ed31316abf714ece8ce64e77be7ee4f613 100644 (file)
@@ -607,7 +607,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);
index 9d342bf045f2f13f1e20ab0e6b5f8df391b39e77..dcf14e76f4e6792f2fc9118fb7124438f861e143 100644 (file)
@@ -500,7 +500,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);
index 8c089d9d3553eee1fe261252390fb2dbbb534ea3..e0385ea31b011c43de53a7beef4888594ee47fb3 100644 (file)
@@ -63,7 +63,7 @@ typedef struct {
        bool                            recv_buff_is_set;       //!< Whether we were provided with a recv_buff
        bool                            dynamic_clients;        //!< whether we have dynamic clients
 
-       fr_client_list_t                        *clients;               //!< local clients
+       fr_client_list_t                *clients;               //!< local clients
 
        fr_trie_t                       *trie;                  //!< for parsed networks
        fr_ipaddr_t                     *allow;                 //!< allowed networks for dynamic clients
@@ -459,7 +459,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);
index 5fc82c14dc5ce4653f09d6485d8b4a525dd098dc..f58fcb34942d241b1fe7bcb013712eac1e7ba8ee 100644 (file)
@@ -453,7 +453,7 @@ static int mod_instantiate(module_inst_ctx_t const *mctx)
                }
        }
 
-       ci = cf_parent(inst->cs); /* listen { ... } */
+       ci = cf_section_to_item(mctx->mi->parent->conf); /* listen { ... } */
        fr_assert(ci != NULL);
        ci = cf_parent(ci);
        fr_assert(ci != NULL);