[vlc-devel] commit: Remove unused vlc_object_lock and vlc_object_unlock ( Rémi Denis-Courmont )

git version control git at videolan.org
Thu Mar 5 18:14:43 CET 2009


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Mar  5 19:08:05 2009 +0200| [4c2ec0499295ca1b305b5aa1b5a3b372c200f3aa] | committer: Rémi Denis-Courmont 

Remove unused vlc_object_lock and vlc_object_unlock

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

 include/vlc_objects.h |    8 --------
 src/libvlc.h          |    1 -
 src/libvlccore.sym    |    2 --
 src/misc/objects.c    |   15 ---------------
 4 files changed, 0 insertions(+), 26 deletions(-)

diff --git a/include/vlc_objects.h b/include/vlc_objects.h
index 9fa9a95..e2fda54 100644
--- a/include/vlc_objects.h
+++ b/include/vlc_objects.h
@@ -111,14 +111,6 @@ VLC_EXPORT( void, vlc_list_release, ( vlc_list_t * ) );
     __vlc_list_children( VLC_OBJECT(a) )
 
 /* Objects and threading */
-VLC_EXPORT( void, __vlc_object_lock, ( vlc_object_t * ) );
-#define vlc_object_lock( obj ) \
-    __vlc_object_lock( VLC_OBJECT( obj ) )
-
-VLC_EXPORT( void, __vlc_object_unlock, ( vlc_object_t * ) );
-#define vlc_object_unlock( obj ) \
-    __vlc_object_unlock( VLC_OBJECT( obj ) )
-
 VLC_EXPORT( void, __vlc_object_kill, ( vlc_object_t * ) );
 #define vlc_object_kill(a) \
     __vlc_object_kill( VLC_OBJECT(a) )
diff --git a/src/libvlc.h b/src/libvlc.h
index 608d1c9..710848f 100644
--- a/src/libvlc.h
+++ b/src/libvlc.h
@@ -166,7 +166,6 @@ typedef struct vlc_object_internals_t
     bool            b_thread;
 
     /* Objects thread synchronization */
-    vlc_mutex_t     lock;
     int             pipes[2];
 
     /* Objects management */
diff --git a/src/libvlccore.sym b/src/libvlccore.sym
index fe57733..633a27a 100644
--- a/src/libvlccore.sym
+++ b/src/libvlccore.sym
@@ -467,10 +467,8 @@ __vlc_object_find
 vlc_object_find_name
 __vlc_object_hold
 __vlc_object_kill
-__vlc_object_lock
 __vlc_object_release
 __vlc_object_set_destructor
-__vlc_object_unlock
 vlc_plugin_set
 vlc_poll
 vlc_rand_bytes
diff --git a/src/misc/objects.c b/src/misc/objects.c
index 6b0f569..3f55190 100644
--- a/src/misc/objects.c
+++ b/src/misc/objects.c
@@ -163,7 +163,6 @@ void *__vlc_custom_create( vlc_object_t *p_this, size_t i_size,
     p_new->p_private = NULL;
 
     /* Initialize mutexes and condvars */
-    vlc_mutex_init( &p_priv->lock );
     vlc_mutex_init( &p_priv->var_lock );
     vlc_cond_init( &p_priv->var_wait );
     p_priv->pipes[0] = p_priv->pipes[1] = -1;
@@ -292,7 +291,6 @@ static void vlc_object_destroy( vlc_object_t *p_this )
     FREENULL( p_this->psz_object_name );
 
     vlc_spin_destroy( &p_priv->ref_spin );
-    vlc_mutex_destroy( &p_priv->lock );
     if( p_priv->pipes[1] != -1 && p_priv->pipes[1] != p_priv->pipes[0] )
         close( p_priv->pipes[1] );
     if( p_priv->pipes[0] != -1 )
@@ -304,19 +302,6 @@ static void vlc_object_destroy( vlc_object_t *p_this )
 }
 
 
-/** Inter-object signaling */
-
-void __vlc_object_lock( vlc_object_t *obj )
-{
-    vlc_mutex_lock( &(vlc_internals(obj)->lock) );
-}
-
-void __vlc_object_unlock( vlc_object_t *obj )
-{
-    vlc_assert_locked( &(vlc_internals(obj)->lock) );
-    vlc_mutex_unlock( &(vlc_internals(obj)->lock) );
-}
-
 #ifdef WIN32
 # include <winsock2.h>
 # include <ws2tcpip.h>




More information about the vlc-devel mailing list