]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
track: Disallow double allocations
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Thu, 9 Apr 2020 02:34:28 +0000 (21:34 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Thu, 9 Apr 2020 02:34:28 +0000 (21:34 -0500)
src/modules/rlm_radius/track.c

index 1505af683405b567db72f11faa0421071f6025c6..32bc36e3e74a8e6fe9a73ace00b573154fade598 100644 (file)
@@ -115,6 +115,8 @@ int radius_track_entry_reserve(radius_track_entry_t **te_out,
 {
        radius_track_entry_t *te;
 
+       rad_assert(!*te_out);   /* Must be NULL */
+
 retry:
        te = fr_dlist_head(&tt->free_list);
        if (te) {