misc/events.c: Fix a NULL ptr access.
authorPierre d'Herbemont <pdherbemont@videolan.org>
Mon, 14 Jan 2008 19:28:09 +0000 (19:28 +0000)
committerPierre d'Herbemont <pdherbemont@videolan.org>
Mon, 14 Jan 2008 19:28:09 +0000 (19:28 +0000)
src/misc/events.c

index 6bbf01a..50a5110 100644 (file)
@@ -210,6 +210,10 @@ void vlc_event_send( vlc_event_manager_t * p_em,
  
     /* Call the function attached */
     cached_listener = array_of_cached_listeners;
+
+    if( !listeners_group )
+        return;
+
     vlc_mutex_lock( &p_em->event_sending_lock );
 
     /* Track item removed from *this* thread, with a simple flag */