From: Alan T. DeKok Date: Tue, 1 Apr 2025 01:33:38 +0000 (-0400) Subject: we already have "len". No need to call talloc array length X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fc8bc8524e9b6fcc7c5bc209c3117416244bffdc;p=thirdparty%2Ffreeradius-server.git we already have "len". No need to call talloc array length --- diff --git a/src/lib/util/value.c b/src/lib/util/value.c index dfa9b691c94..90e58607dbc 100644 --- a/src/lib/util/value.c +++ b/src/lib/util/value.c @@ -4112,7 +4112,7 @@ int fr_value_box_bstr_alloc(TALLOC_CTX *ctx, char **out, fr_value_box_t *dst, fr fr_value_box_init(dst, FR_TYPE_STRING, enumv, tainted); dst->vb_strvalue = str; - dst->vb_length = talloc_array_length(str) - 1; + dst->vb_length = len; if (out) *out = str;