From: Alan T. DeKok Date: Sat, 3 Feb 2024 15:27:13 +0000 (-0500) Subject: some protocols don't have init/free X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=129d2db6f809ca2bb5e047f39c51b2e726825214;p=thirdparty%2Ffreeradius-server.git some protocols don't have init/free --- diff --git a/src/lib/util/dict_util.c b/src/lib/util/dict_util.c index 68762f619b0..3f8e29a48c3 100644 --- a/src/lib/util/dict_util.c +++ b/src/lib/util/dict_util.c @@ -3347,9 +3347,7 @@ static int _dict_free(fr_dict_t *dict) /* * If we called init(), then call free() */ - if (dict->loaded) { - fr_assert(dict->proto); - fr_assert(dict->proto->free); + if (dict->loaded && dict->proto && dict->proto->free) { dict->proto->free(); }