From: Alan T. DeKok Date: Mon, 17 Jul 2023 18:25:04 +0000 (-0400) Subject: remove unused function X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aaa948e3782cbd04950caada84df7938a5adac25;p=thirdparty%2Ffreeradius-server.git remove unused function --- diff --git a/src/lib/util/dict.h b/src/lib/util/dict.h index e5e4af0b0c7..075895a8bbe 100644 --- a/src/lib/util/dict.h +++ b/src/lib/util/dict.h @@ -473,8 +473,6 @@ fr_dict_attr_t const *fr_dict_attr_by_oid(fr_dict_attr_err_t *err, fr_dict_attr_t const *parent, char const *oid) CC_HINT(nonnull(2,3)); -bool fr_dict_attr_compatible(fr_dict_attr_t const *a, fr_dict_attr_t const *b) CC_HINT(nonnull); - bool fr_dict_attr_can_contain(fr_dict_attr_t const *parent, fr_dict_attr_t const *child) CC_HINT(nonnull); /** @} */ diff --git a/src/lib/util/dict_util.c b/src/lib/util/dict_util.c index e165b417ff8..bc089514613 100644 --- a/src/lib/util/dict_util.c +++ b/src/lib/util/dict_util.c @@ -4286,39 +4286,6 @@ void fr_dict_attr_verify(char const *file, int line, fr_dict_attr_t const *da) } } -/** See if two DAs are compatible, and can contain the same things. - * - */ -bool fr_dict_attr_compatible(fr_dict_attr_t const *a, fr_dict_attr_t const *b) -{ - fr_dict_attr_t const *ref; - - /* - * They're the same DA, they're compatible. - */ - if (a == b) return true; - - /* - * @todo - TLVs and STRUCTs can clone other things. In - * which case we want to allow the various cloned src/dst - * attributes to be able to copy child VPs to each other. - */ - - if ((a->type != FR_TYPE_GROUP) && (b->type != FR_TYPE_GROUP)) return false; - - /* - * Groups can reference other things. In which case we - * check the reference, not the input attribute. - */ - ref = fr_dict_attr_ref(a); - if (ref) a = ref; - - ref = fr_dict_attr_ref(b); - if (ref) b = ref; - - return (a == b); -} - /** See if a structural da is allowed to contain another da * * We have some complex rules with different structural types,