Commit bb54273e authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont Committed by Jean-Baptiste Kempf

tdestroy: use assert()

(cherry picked from commit 2b268061)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent 8c6f1380
......@@ -93,9 +93,11 @@ void vlc_tdestroy (void *root, void (*freenode) (void *))
vlc_mutex_lock (&smallest.lock);
for (size_t i = 0; i < count; i++)
{
smallest.node = tab[i];
if (tdelete (smallest.node, &root, cmp_smallest) == NULL)
abort ();
void *node = tab[i];
smallest.node = node;
node = tdelete (node, &root, cmp_smallest);
assert (node != NULL);
}
vlc_mutex_unlock (&smallest.lock);
assert (root == NULL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment