From 53b2aa8364e6887072b929c7053d78a17dd35b37 Mon Sep 17 00:00:00 2001 From: Antoine Cellerier Date: Sat, 1 Sep 2007 20:37:17 +0000 Subject: [PATCH] Fix the use of commands list, tree and vars in the rc interface which were broken since [21138]. --- src/misc/objects.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/misc/objects.c b/src/misc/objects.c index 734c314c14..32c37ba8a6 100644 --- a/src/misc/objects.c +++ b/src/misc/objects.c @@ -156,7 +156,7 @@ vlc_object_t *vlc_custom_create( vlc_object_t *p_this, size_t i_size, libvlc_global_data_t *p_libvlc_global = vlc_global(); if( i_type == VLC_OBJECT_LIBVLC ) { - p_new->p_libvlc = (libvlc_int_t*)p_new; + p_new->p_libvlc = (libvlc_int_t*)p_new; p_priv->b_attached = VLC_TRUE; } else @@ -192,7 +192,10 @@ vlc_object_t *vlc_custom_create( vlc_object_t *p_this, size_t i_size, if( i_type == VLC_OBJECT_GLOBAL ) { vlc_mutex_init( p_new, &structure_lock ); + } + if( i_type == VLC_OBJECT_LIBVLC ) + { var_Create( p_new, "list", VLC_VAR_STRING | VLC_VAR_ISCOMMAND ); var_AddCallback( p_new, "list", DumpCommand, NULL ); var_Create( p_new, "tree", VLC_VAR_STRING | VLC_VAR_ISCOMMAND ); -- 2.39.2