[vlc-devel] commit: libvlc_InternalDestroy: remove dead code ( Rémi Denis-Courmont )

git version control git at videolan.org
Tue Jun 24 18:21:38 CEST 2008


vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Tue Jun 24 19:23:41 2008 +0300| [6465bbf725b1155954a7472ec401576c305eb048]

libvlc_InternalDestroy: remove dead code

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

 src/control/core.c            |    2 +-
 src/control/libvlc_internal.h |    2 +-
 src/libvlc.c                  |    4 +---
 3 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/src/control/core.c b/src/control/core.c
index 50664d1..9155bc2 100644
--- a/src/control/core.c
+++ b/src/control/core.c
@@ -164,7 +164,7 @@ void libvlc_release( libvlc_instance_t *p_instance )
         vlc_mutex_destroy( lock );
         vlc_mutex_destroy( &p_instance->event_callback_lock );
         libvlc_InternalCleanup( p_instance->p_libvlc_int );
-        libvlc_InternalDestroy( p_instance->p_libvlc_int, false );
+        libvlc_InternalDestroy( p_instance->p_libvlc_int );
         free( p_instance );
     }
 }
diff --git a/src/control/libvlc_internal.h b/src/control/libvlc_internal.h
index 39b2d12..a291858 100644
--- a/src/control/libvlc_internal.h
+++ b/src/control/libvlc_internal.h
@@ -42,7 +42,7 @@
 VLC_EXPORT (libvlc_int_t *, libvlc_InternalCreate, ( void ) );
 VLC_EXPORT (int, libvlc_InternalInit, ( libvlc_int_t *, int, const char *ppsz_argv[] ) );
 VLC_EXPORT (int, libvlc_InternalCleanup, ( libvlc_int_t * ) );
-VLC_EXPORT (int, libvlc_InternalDestroy, ( libvlc_int_t *, bool ) );
+VLC_EXPORT (int, libvlc_InternalDestroy, ( libvlc_int_t * ) );
 
 VLC_EXPORT (int, libvlc_InternalAddIntf, ( libvlc_int_t *, const char * ) );
 
diff --git a/src/libvlc.c b/src/libvlc.c
index 023aa6e..9181821 100644
--- a/src/libvlc.c
+++ b/src/libvlc.c
@@ -1023,9 +1023,8 @@ int libvlc_InternalCleanup( libvlc_int_t *p_libvlc )
  * termination, and destroys their structure.
  * It stops the thread systems: no instance can run after this has run
  * \param p_libvlc the instance to destroy
- * \param b_release whether we should do a release on the instance
  */
-int libvlc_InternalDestroy( libvlc_int_t *p_libvlc, bool b_release )
+int libvlc_InternalDestroy( libvlc_int_t *p_libvlc )
 {
     if( !p_libvlc )
         return VLC_EGENERIC;
@@ -1084,7 +1083,6 @@ int libvlc_InternalDestroy( libvlc_int_t *p_libvlc, bool b_release )
     vlc_cond_destroy (&priv->threads_wait);
     vlc_mutex_destroy (&priv->threads_lock);
 
-    if( b_release ) vlc_object_release( p_libvlc );
     vlc_object_release( p_libvlc );
     p_libvlc = NULL;
 




More information about the vlc-devel mailing list