From: Arran Cudbard-Bell Date: Sun, 29 Nov 2020 17:25:56 +0000 (-0700) Subject: Remove support for old list separators X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f77bebfb14ee0e7b80075cfd4ae1f591e408c8ad;p=thirdparty%2Ffreeradius-server.git Remove support for old list separators There's no point in maintaining backwards compatibility when the reference syntax has changed so significantly --- diff --git a/src/lib/server/tmpl.h b/src/lib/server/tmpl.h index c76d3a9fb27..98667f2b88b 100644 --- a/src/lib/server/tmpl.h +++ b/src/lib/server/tmpl.h @@ -443,8 +443,6 @@ struct tmpl_s { fr_dlist_head_t rr; //!< Request to search or insert in. - bool old_list_sep; //!< Print ':' - pair_list_t list; //!< List to search or insert in. ///< deprecated. diff --git a/src/lib/server/tmpl_tokenize.c b/src/lib/server/tmpl_tokenize.c index 7107a5dbeb0..c0c947d64b2 100644 --- a/src/lib/server/tmpl_tokenize.c +++ b/src/lib/server/tmpl_tokenize.c @@ -1913,11 +1913,10 @@ ssize_t tmpl_afrom_attr_substr(TALLOC_CTX *ctx, tmpl_attr_error_t *err, * * This will either be after: * - A zero length list, i.e. just after the prefix '&', in which case we require an attribue - * - A ':' or '.' and then an allowed char, so we're sure it's not just a bare list ref. + * - '.' and then an allowed char, so we're sure it's not just a bare list ref. */ if ((list_len == 0) || - (((fr_sbuff_next_if_char(&our_name, ':') && (vpt->data.attribute.old_list_sep = true)) || - fr_sbuff_next_if_char(&our_name, '.')) && fr_sbuff_is_in_charset(&our_name, fr_dict_attr_allowed_chars))) { + (fr_sbuff_next_if_char(&our_name, '.') && fr_sbuff_is_in_charset(&our_name, fr_dict_attr_allowed_chars))) { ret = tmpl_attr_afrom_attr_substr(vpt, err, vpt, t_rules->attr_parent, &our_name, p_rules, t_rules, 0); if (ret < 0) goto error; @@ -3436,11 +3435,11 @@ ssize_t tmpl_attr_print(fr_sbuff_t *out, tmpl_t const *vpt, tmpl_attr_prefix_t a FR_SBUFF_IN_TABLE_STR_RETURN(&our_out, pair_list_table, tmpl_list(vpt), ""); if (fr_dlist_num_elements(&vpt->data.attribute.ar)) { - FR_SBUFF_IN_CHAR_RETURN(&our_out, vpt->data.attribute.old_list_sep ? ':' : '.'); + FR_SBUFF_IN_CHAR_RETURN(&our_out, '.'); } } else if (printed_rr) { /* Request qualifier with no list qualifier */ if (fr_dlist_num_elements(&vpt->data.attribute.ar)) { - FR_SBUFF_IN_CHAR_RETURN(&our_out, vpt->data.attribute.old_list_sep ? ':' : '.'); + FR_SBUFF_IN_CHAR_RETURN(&our_out, '.'); } }