[vlc-commits] variables: fix callback setup leak with non existent variable
Francois Cartegnie
git at videolan.org
Wed Feb 13 12:15:15 CET 2019
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Feb 13 12:14:22 2019 +0100| [e4d5cb0f83e92d98d58649990a218a057aed3ad7] | committer: Francois Cartegnie
variables: fix callback setup leak with non existent variable
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e4d5cb0f83e92d98d58649990a218a057aed3ad7
---
src/misc/variables.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/misc/variables.c b/src/misc/variables.c
index a07684c58a..871c463547 100644
--- a/src/misc/variables.c
+++ b/src/misc/variables.c
@@ -776,6 +776,7 @@ static void AddCallback( vlc_object_t *p_this, const char *psz_name,
vlc_mutex_unlock( &p_priv->var_lock );
msg_Err( p_this, "cannot add callback %p to nonexistent variable '%s'",
entry->p_callback, psz_name );
+ free( entry );
return;
}
More information about the vlc-commits
mailing list