]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Remove needless check for FR_TYPE_NULL (CID #1503975) (#4488)
authorJames Jones <jejones3141@gmail.com>
Thu, 5 May 2022 12:52:12 +0000 (07:52 -0500)
committerGitHub <noreply@github.com>
Thu, 5 May 2022 12:52:12 +0000 (14:52 +0200)
src/lib/server/tmpl_tokenize.c

index d17990331402b8aa362bb61d91c79aa90e37aca9..9cdc6b577a53b3a64be238f54904880cb902eae9 100644 (file)
@@ -3171,11 +3171,8 @@ int tmpl_cast_set(tmpl_t *vpt, fr_type_t dst_type)
         *      By default, tmpl types cannot be cast to anything.
         */
        default:
-               if (dst_type != FR_TYPE_NULL) {
-                       fr_strerror_const("Cannot use cast here.");
-                       return -1;
-               }
-               break;
+               fr_strerror_const("Cannot use cast here.");
+               return -1;
 
        /*
         *      These tmpl types are effectively of data type