From: Alan T. DeKok Date: Thu, 17 Dec 2020 14:50:10 +0000 (-0500) Subject: follow references for non-group attributes X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1af587c3a33b05a0bd172fb5acd050737d0b5fd6;p=thirdparty%2Ffreeradius-server.git follow references for non-group attributes --- diff --git a/src/lib/util/dict_util.c b/src/lib/util/dict_util.c index 8b2d5aca481..6252ebff38c 100644 --- a/src/lib/util/dict_util.c +++ b/src/lib/util/dict_util.c @@ -1828,6 +1828,17 @@ ssize_t fr_dict_oid_component(fr_dict_attr_err_t *err, return -fr_sbuff_marker_release_behind(&start); } + /* + * Follow references, unless this attribute is a grouping + * attribute. + */ + if (child->type != FR_TYPE_GROUP) { + fr_dict_attr_t const *ref; + + ref = fr_dict_attr_ref(child); + if (ref) child = ref; + } + *out = child; return fr_sbuff_marker_release_behind(&start);