From 2dffeb14fb0b1cd571aace3cde1c9c8dcc48eb64 Mon Sep 17 00:00:00 2001 From: =?utf8?q?R=C3=A9mi=20Denis-Courmont?= Date: Thu, 16 Aug 2007 15:55:55 +0000 Subject: [PATCH] vlc_global_object: return the global (process-wide) LibVLC object It is mostly useful to register global mutexes and such things. --- include/vlc_objects.h | 1 + src/libvlc-common.c | 5 +++++ src/libvlc.sym | 1 + 3 files changed, 7 insertions(+) diff --git a/include/vlc_objects.h b/include/vlc_objects.h index a906d517cc..7e24d4ea67 100644 --- a/include/vlc_objects.h +++ b/include/vlc_objects.h @@ -109,6 +109,7 @@ VLC_EXPORT( void, __vlc_object_release, ( vlc_object_t * ) ); VLC_EXPORT( vlc_list_t *, __vlc_list_find, ( vlc_object_t *, int, int ) ); VLC_EXPORT( void, vlc_list_release, ( vlc_list_t * ) ); VLC_EXPORT( libvlc_int_t *, vlc_current_object, ( int ) ); +VLC_EXPORT( vlc_object_t *, vlc_global_object, ( void ) ); /*}@*/ diff --git a/src/libvlc-common.c b/src/libvlc-common.c index 68e87fa58e..b6efb7cc51 100644 --- a/src/libvlc-common.c +++ b/src/libvlc-common.c @@ -122,6 +122,11 @@ static int VerboseCallback( vlc_object_t *, char const *, static void InitDeviceValues( libvlc_int_t * ); +vlc_object_t * vlc_global_object( void ) +{ + return VLC_OBJECT( &libvlc_global ); +} + /***************************************************************************** * vlc_current_object: return the current object. ***************************************************************************** diff --git a/src/libvlc.sym b/src/libvlc.sym index edb211f2bb..75ec636225 100644 --- a/src/libvlc.sym +++ b/src/libvlc.sym @@ -362,6 +362,7 @@ VLC_VariableSet __vlc_cond_destroy __vlc_cond_init vlc_current_object +vlc_global_object vlc_error VLC_Error __vlc_execve -- 2.39.2