]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Fix assert
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Mon, 23 Jan 2017 17:55:55 +0000 (17:55 +0000)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Mon, 23 Jan 2017 17:55:55 +0000 (17:55 +0000)
src/main/map.c

index 6d448efbaf311912fdb423809b89baf5da6ffa5d..ee89f6125c55f5fac5b1cf8be29325cf3bb80476 100644 (file)
@@ -923,7 +923,7 @@ int map_to_vp(TALLOC_CTX *ctx, VALUE_PAIR **out, REQUEST *request, vp_map_t cons
                                vp = fr_pair_cursor_remove(&from);
                                talloc_free(vp);
 
-                               if (new->vp_type == PW_TYPE_STRING) rad_assert(new->vp_strvalue != NULL);
+                               rad_assert((new->vp_type != PW_TYPE_STRING) || (new->vp_strvalue != NULL));
 
                                new->op = map->op;
                                new->tag = map->lhs->tmpl_tag;