[vlc-commits] src: dialog: add assert on getting context

Francois Cartegnie git at videolan.org
Tue May 3 18:45:42 CEST 2016


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon May  2 09:55:11 2016 +0200| [df750c514bef6a6905548b8d16354187e9d1e5e4] | committer: Francois Cartegnie

src: dialog: add assert on getting context

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=df750c514bef6a6905548b8d16354187e9d1e5e4
---

 src/interface/dialog.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/src/interface/dialog.c b/src/interface/dialog.c
index 11b4595..7e3e390 100644
--- a/src/interface/dialog.c
+++ b/src/interface/dialog.c
@@ -744,6 +744,7 @@ vlc_dialog_id_set_context(vlc_dialog_id *p_id, void *p_context)
 void *
 vlc_dialog_id_get_context(vlc_dialog_id *p_id)
 {
+    assert(p_id != NULL);
     vlc_mutex_lock(&p_id->lock);
     void *p_context = p_id->p_context;
     vlc_mutex_unlock(&p_id->lock);



More information about the vlc-commits mailing list