control/media_list_view.c: Implement unimplemented retain/release function.
authorPierre d'Herbemont <pdherbemont@videolan.org>
Mon, 15 Oct 2007 15:23:44 +0000 (15:23 +0000)
committerPierre d'Herbemont <pdherbemont@videolan.org>
Mon, 15 Oct 2007 15:23:44 +0000 (15:23 +0000)
include/vlc/libvlc.h
src/control/media_list_view.c

index 64f9f8d..7d0f0c6 100644 (file)
@@ -512,6 +512,9 @@ VLC_PUBLIC_API libvlc_event_manager_t *
 VLC_PUBLIC_API void
     libvlc_media_list_view_retain( libvlc_media_list_view_t * p_mlv );
 
+VLC_PUBLIC_API void
+    libvlc_media_list_view_release( libvlc_media_list_view_t * p_mlv );
+
 VLC_PUBLIC_API int
     libvlc_media_list_view_count(  libvlc_media_list_view_t * p_mlv,
                                    libvlc_exception_t * p_e );
index b80ce0c..196265e 100644 (file)
@@ -124,7 +124,7 @@ libvlc_media_list_view_new( libvlc_media_list_t * p_mlist,
     p_mlv->pf_item_at_index = pf_item_at_index;
     p_mlv->pf_release       = pf_release;
 
-    p_mlv->this_view_data = this_view_data;
+    p_mlv->p_this_view_data = this_view_data;
 
     vlc_mutex_init( p_mlv->p_libvlc_instance->p_libvlc_int, &p_mlv->object_lock );
     p_mlv->i_refcount = 1;
@@ -137,6 +137,17 @@ libvlc_media_list_view_new( libvlc_media_list_t * p_mlist,
  * Public libvlc functions
  */
 
+/**************************************************************************
+ *       libvlc_media_list_view_retain (Public)
+ **************************************************************************/
+void
+libvlc_media_list_view_release( libvlc_media_list_view_t * p_mlv )
+{
+    vlc_mutex_lock( &p_mlv->object_lock );
+    p_mlv->i_refcount++;
+    vlc_mutex_unlock( &p_mlv->object_lock );
+}
+
 /**************************************************************************
  *       libvlc_media_list_view_release (Public)
  **************************************************************************/