Commit ba6501f3 authored by dionoea's avatar dionoea

s/pl_Yield/pl_Hold/

parent 7060dbb9
...@@ -273,8 +273,8 @@ enum pl_locked_state ...@@ -273,8 +273,8 @@ enum pl_locked_state
#define PL_LOCK vlc_object_lock( p_playlist ) #define PL_LOCK vlc_object_lock( p_playlist )
#define PL_UNLOCK vlc_object_unlock( p_playlist ) #define PL_UNLOCK vlc_object_unlock( p_playlist )
VLC_EXPORT( playlist_t *, __pl_Yield, ( vlc_object_t * ) ); VLC_EXPORT( playlist_t *, __pl_Hold, ( vlc_object_t * ) );
#define pl_Yield( a ) __pl_Yield( VLC_OBJECT(a) ) #define pl_Hold( a ) __pl_Hold( VLC_OBJECT(a) )
VLC_EXPORT( void, __pl_Release, ( vlc_object_t * ) ); VLC_EXPORT( void, __pl_Release, ( vlc_object_t * ) );
#define pl_Release(a) __pl_Release( VLC_OBJECT(a) ) #define pl_Release(a) __pl_Release( VLC_OBJECT(a) )
...@@ -420,7 +420,7 @@ static inline int playlist_Import( playlist_t *p_playlist, const char *psz_file) ...@@ -420,7 +420,7 @@ static inline int playlist_Import( playlist_t *p_playlist, const char *psz_file)
#define pl_CurrentInput(a) __pl_CurrentInput( VLC_OBJECT(a) ) #define pl_CurrentInput(a) __pl_CurrentInput( VLC_OBJECT(a) )
static inline input_thread_t * __pl_CurrentInput( vlc_object_t * p_this ) static inline input_thread_t * __pl_CurrentInput( vlc_object_t * p_this )
{ {
playlist_t * p_playlist = pl_Yield( p_this ); playlist_t * p_playlist = pl_Hold( p_this );
if( !p_playlist ) return NULL; if( !p_playlist ) return NULL;
input_thread_t * p_input = playlist_CurrentInput( p_playlist ); input_thread_t * p_input = playlist_CurrentInput( p_playlist );
pl_Release( p_this ); pl_Release( p_this );
......
...@@ -187,7 +187,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -187,7 +187,7 @@ static int Open( vlc_object_t *p_this )
if( p_sys->i_track < 0 && i_mrl_tracknum <= 0 ) if( p_sys->i_track < 0 && i_mrl_tracknum <= 0 )
{ {
/* We only do separate items if the whole disc is requested */ /* We only do separate items if the whole disc is requested */
playlist_t *p_playlist = pl_Yield( p_access ); playlist_t *p_playlist = pl_Hold( p_access );
i_ret = -1; i_ret = -1;
if( p_playlist ) if( p_playlist )
......
...@@ -864,7 +864,7 @@ CDDAFixupPlaylist( access_t *p_access, cdda_data_t *p_cdda, ...@@ -864,7 +864,7 @@ CDDAFixupPlaylist( access_t *p_access, cdda_data_t *p_cdda,
#endif #endif
if (! p_cdda->b_nav_mode ) { if (! p_cdda->b_nav_mode ) {
p_playlist = pl_Yield( p_access ); p_playlist = pl_Hold( p_access );
} }
if( b_single_track || p_cdda->b_nav_mode ) { if( b_single_track || p_cdda->b_nav_mode ) {
......
...@@ -208,7 +208,7 @@ static ssize_t Read( access_t *p_access, uint8_t *p_buffer, size_t i_len) ...@@ -208,7 +208,7 @@ static ssize_t Read( access_t *p_access, uint8_t *p_buffer, size_t i_len)
if( psz_name == NULL ) if( psz_name == NULL )
return VLC_ENOMEM; return VLC_ENOMEM;
playlist_t *p_playlist = pl_Yield( p_access ); playlist_t *p_playlist = pl_Hold( p_access );
input_thread_t *p_input = (input_thread_t*)vlc_object_find( p_access, VLC_OBJECT_INPUT, FIND_PARENT ); input_thread_t *p_input = (input_thread_t*)vlc_object_find( p_access, VLC_OBJECT_INPUT, FIND_PARENT );
playlist_item_t *p_item_in_category; playlist_item_t *p_item_in_category;
......
...@@ -295,7 +295,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -295,7 +295,7 @@ static int Open( vlc_object_t *p_this )
if( config_GetInt(p_this, SOUT_CFG_PREFIX "bonjour") ) if( config_GetInt(p_this, SOUT_CFG_PREFIX "bonjour") )
{ {
char *psz_txt, *psz_name; char *psz_txt, *psz_name;
playlist_t *p_playlist = pl_Yield( p_access ); playlist_t *p_playlist = pl_Hold( p_access );
char *psz_uri = input_item_GetURI( p_playlist->status.p_item->p_input ); char *psz_uri = input_item_GetURI( p_playlist->status.p_item->p_input );
char *psz_newuri = psz_uri; char *psz_newuri = psz_uri;
......
...@@ -437,7 +437,7 @@ static void FollowAnchor ( intf_thread_t *p_intf ) ...@@ -437,7 +437,7 @@ static void FollowAnchor ( intf_thread_t *p_intf )
mtime_t i_seconds; mtime_t i_seconds;
vlc_value_t time; vlc_value_t time;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
/* Get new URL */ /* Get new URL */
p_current_item = p_playlist->status.p_item; p_current_item = p_playlist->status.p_item;
...@@ -641,7 +641,7 @@ void GoBack( intf_thread_t *p_intf ) ...@@ -641,7 +641,7 @@ void GoBack( intf_thread_t *p_intf )
#endif #endif
/* Find the playlist */ /* Find the playlist */
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
/* Retrieve navigation history from playlist */ /* Retrieve navigation history from playlist */
if( var_Get( p_playlist, "navigation-history", &history ) != VLC_SUCCESS || if( var_Get( p_playlist, "navigation-history", &history ) != VLC_SUCCESS ||
...@@ -713,7 +713,7 @@ void GoForward( intf_thread_t *p_intf ) ...@@ -713,7 +713,7 @@ void GoForward( intf_thread_t *p_intf )
#endif #endif
/* Find the playlist */ /* Find the playlist */
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
/* Retrieve navigation history from playlist */ /* Retrieve navigation history from playlist */
if( var_Get( p_playlist, "navigation-history", &history ) != VLC_SUCCESS || if( var_Get( p_playlist, "navigation-history", &history ) != VLC_SUCCESS ||
......
...@@ -694,7 +694,7 @@ static void ParseVorbisComments( decoder_t *p_dec ) ...@@ -694,7 +694,7 @@ static void ParseVorbisComments( decoder_t *p_dec )
r->pf_peak[AUDIO_REPLAY_GAIN_ALBUM] = atof( psz_value ); r->pf_peak[AUDIO_REPLAY_GAIN_ALBUM] = atof( psz_value );
} }
} }
var_SetInteger( pl_Yield( p_input ), "item-change", p_item->i_id ); var_SetInteger( pl_Hold( p_input ), "item-change", p_item->i_id );
pl_Release( p_input ); pl_Release( p_input );
free( psz_comment ); free( psz_comment );
i++; i++;
......
...@@ -126,7 +126,7 @@ vlc_module_end(); ...@@ -126,7 +126,7 @@ vlc_module_end();
DBUS_METHOD( Quit ) DBUS_METHOD( Quit )
{ /* exits vlc */ { /* exits vlc */
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
playlist_Stop( p_playlist ); playlist_Stop( p_playlist );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
vlc_object_kill(((vlc_object_t*)p_this)->p_libvlc); vlc_object_kill(((vlc_object_t*)p_this)->p_libvlc);
...@@ -166,7 +166,7 @@ DBUS_METHOD( PositionGet ) ...@@ -166,7 +166,7 @@ DBUS_METHOD( PositionGet )
vlc_value_t position; vlc_value_t position;
dbus_int32_t i_pos; dbus_int32_t i_pos;
playlist_t *p_playlist = pl_Yield( ((vlc_object_t*) p_this) ); playlist_t *p_playlist = pl_Hold( ((vlc_object_t*) p_this) );
PL_LOCK; PL_LOCK;
input_thread_t *p_input = p_playlist->p_input; input_thread_t *p_input = p_playlist->p_input;
...@@ -205,7 +205,7 @@ DBUS_METHOD( PositionSet ) ...@@ -205,7 +205,7 @@ DBUS_METHOD( PositionSet )
dbus_error_free( &error ); dbus_error_free( &error );
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
} }
p_playlist = pl_Yield( ((vlc_object_t*) p_this) ); p_playlist = pl_Hold( ((vlc_object_t*) p_this) );
PL_LOCK; PL_LOCK;
input_thread_t *p_input = p_playlist->p_input; input_thread_t *p_input = p_playlist->p_input;
...@@ -265,7 +265,7 @@ DBUS_METHOD( VolumeSet ) ...@@ -265,7 +265,7 @@ DBUS_METHOD( VolumeSet )
DBUS_METHOD( Next ) DBUS_METHOD( Next )
{ /* next playlist item */ { /* next playlist item */
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( ((vlc_object_t*) p_this) ); playlist_t *p_playlist = pl_Hold( ((vlc_object_t*) p_this) );
playlist_Next( p_playlist ); playlist_Next( p_playlist );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
REPLY_SEND; REPLY_SEND;
...@@ -274,7 +274,7 @@ DBUS_METHOD( Next ) ...@@ -274,7 +274,7 @@ DBUS_METHOD( Next )
DBUS_METHOD( Prev ) DBUS_METHOD( Prev )
{ /* previous playlist item */ { /* previous playlist item */
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( ((vlc_object_t*) p_this) ); playlist_t *p_playlist = pl_Hold( ((vlc_object_t*) p_this) );
playlist_Prev( p_playlist ); playlist_Prev( p_playlist );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
REPLY_SEND; REPLY_SEND;
...@@ -283,7 +283,7 @@ DBUS_METHOD( Prev ) ...@@ -283,7 +283,7 @@ DBUS_METHOD( Prev )
DBUS_METHOD( Stop ) DBUS_METHOD( Stop )
{ /* stop playing */ { /* stop playing */
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( ((vlc_object_t*) p_this) ); playlist_t *p_playlist = pl_Hold( ((vlc_object_t*) p_this) );
playlist_Stop( p_playlist ); playlist_Stop( p_playlist );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
REPLY_SEND; REPLY_SEND;
...@@ -308,7 +308,7 @@ DBUS_METHOD( GetStatus ) ...@@ -308,7 +308,7 @@ DBUS_METHOD( GetStatus )
DBUS_METHOD( Pause ) DBUS_METHOD( Pause )
{ {
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
playlist_Pause( p_playlist ); playlist_Pause( p_playlist );
pl_Release( (vlc_object_t*) p_this ); pl_Release( (vlc_object_t*) p_this );
REPLY_SEND; REPLY_SEND;
...@@ -317,7 +317,7 @@ DBUS_METHOD( Pause ) ...@@ -317,7 +317,7 @@ DBUS_METHOD( Pause )
DBUS_METHOD( Play ) DBUS_METHOD( Play )
{ {
REPLY_INIT; REPLY_INIT;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
PL_LOCK; PL_LOCK;
input_thread_t *p_input = p_playlist->p_input; input_thread_t *p_input = p_playlist->p_input;
...@@ -342,7 +342,7 @@ DBUS_METHOD( GetCurrentMetadata ) ...@@ -342,7 +342,7 @@ DBUS_METHOD( GetCurrentMetadata )
{ {
REPLY_INIT; REPLY_INIT;
OUT_ARGUMENTS; OUT_ARGUMENTS;
playlist_t* p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t* p_playlist = pl_Hold( (vlc_object_t*) p_this );
PL_LOCK; PL_LOCK;
if( p_playlist->status.p_item ) if( p_playlist->status.p_item )
GetInputMeta( p_playlist->status.p_item->p_input, &args ); GetInputMeta( p_playlist->status.p_item->p_input, &args );
...@@ -407,7 +407,7 @@ DBUS_METHOD( AddTrack ) ...@@ -407,7 +407,7 @@ DBUS_METHOD( AddTrack )
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED; return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
} }
p_playlist = pl_Yield( (vlc_object_t*) p_this ); p_playlist = pl_Hold( (vlc_object_t*) p_this );
playlist_Add( p_playlist, psz_mrl, NULL, PLAYLIST_APPEND | playlist_Add( p_playlist, psz_mrl, NULL, PLAYLIST_APPEND |
( ( b_play == TRUE ) ? PLAYLIST_GO : 0 ) , ( ( b_play == TRUE ) ? PLAYLIST_GO : 0 ) ,
PLAYLIST_END, true, false ); PLAYLIST_END, true, false );
...@@ -424,7 +424,7 @@ DBUS_METHOD( GetCurrentTrack ) ...@@ -424,7 +424,7 @@ DBUS_METHOD( GetCurrentTrack )
REPLY_INIT; REPLY_INIT;
OUT_ARGUMENTS; OUT_ARGUMENTS;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
dbus_int32_t i_position = p_playlist->i_current_index; dbus_int32_t i_position = p_playlist->i_current_index;
pl_Release( (vlc_object_t*) p_this ); pl_Release( (vlc_object_t*) p_this );
...@@ -441,7 +441,7 @@ DBUS_METHOD( GetMetadata ) ...@@ -441,7 +441,7 @@ DBUS_METHOD( GetMetadata )
dbus_int32_t i_position; dbus_int32_t i_position;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
PL_LOCK; PL_LOCK;
dbus_message_get_args( p_from, &error, dbus_message_get_args( p_from, &error,
...@@ -473,7 +473,7 @@ DBUS_METHOD( GetLength ) ...@@ -473,7 +473,7 @@ DBUS_METHOD( GetLength )
REPLY_INIT; REPLY_INIT;
OUT_ARGUMENTS; OUT_ARGUMENTS;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
dbus_int32_t i_elements = p_playlist->current.i_size; dbus_int32_t i_elements = p_playlist->current.i_size;
pl_Release( (vlc_object_t*) p_this ); pl_Release( (vlc_object_t*) p_this );
...@@ -489,7 +489,7 @@ DBUS_METHOD( DelTrack ) ...@@ -489,7 +489,7 @@ DBUS_METHOD( DelTrack )
dbus_error_init( &error ); dbus_error_init( &error );
dbus_int32_t i_position; dbus_int32_t i_position;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_this ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_this );
dbus_message_get_args( p_from, &error, dbus_message_get_args( p_from, &error,
DBUS_TYPE_INT32, &i_position, DBUS_TYPE_INT32, &i_position,
...@@ -541,7 +541,7 @@ DBUS_METHOD( SetLoop ) ...@@ -541,7 +541,7 @@ DBUS_METHOD( SetLoop )
} }
val.b_bool = ( b_loop == TRUE ) ? true : false ; val.b_bool = ( b_loop == TRUE ) ? true : false ;
p_playlist = pl_Yield( (vlc_object_t*) p_this ); p_playlist = pl_Hold( (vlc_object_t*) p_this );
var_Set ( p_playlist, "loop", val ); var_Set ( p_playlist, "loop", val );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
...@@ -573,7 +573,7 @@ DBUS_METHOD( Repeat ) ...@@ -573,7 +573,7 @@ DBUS_METHOD( Repeat )
val.b_bool = ( b_repeat == TRUE ) ? true : false ; val.b_bool = ( b_repeat == TRUE ) ? true : false ;
p_playlist = pl_Yield( (vlc_object_t*) p_this ); p_playlist = pl_Hold( (vlc_object_t*) p_this );
var_Set ( p_playlist, "repeat", val ); var_Set ( p_playlist, "repeat", val );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
...@@ -605,7 +605,7 @@ DBUS_METHOD( SetRandom ) ...@@ -605,7 +605,7 @@ DBUS_METHOD( SetRandom )
val.b_bool = ( b_random == TRUE ) ? true : false ; val.b_bool = ( b_random == TRUE ) ? true : false ;
p_playlist = pl_Yield( (vlc_object_t*) p_this ); p_playlist = pl_Hold( (vlc_object_t*) p_this );
var_Set ( p_playlist, "random", val ); var_Set ( p_playlist, "random", val );
pl_Release( ((vlc_object_t*) p_this) ); pl_Release( ((vlc_object_t*) p_this) );
...@@ -764,7 +764,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -764,7 +764,7 @@ static int Open( vlc_object_t *p_this )
dbus_connection_flush( p_conn ); dbus_connection_flush( p_conn );
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
PL_LOCK; PL_LOCK;
var_AddCallback( p_playlist, "playlist-current", TrackChange, p_intf ); var_AddCallback( p_playlist, "playlist-current", TrackChange, p_intf );
var_AddCallback( p_playlist, "intf-change", TrackListChangeEmit, p_intf ); var_AddCallback( p_playlist, "intf-change", TrackListChangeEmit, p_intf );
...@@ -792,7 +792,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -792,7 +792,7 @@ static int Open( vlc_object_t *p_this )
static void Close ( vlc_object_t *p_this ) static void Close ( vlc_object_t *p_this )
{ {
intf_thread_t *p_intf = (intf_thread_t*) p_this; intf_thread_t *p_intf = (intf_thread_t*) p_this;
playlist_t *p_playlist = pl_Yield( p_intf );; playlist_t *p_playlist = pl_Hold( p_intf );;
input_thread_t *p_input; input_thread_t *p_input;
PL_LOCK; PL_LOCK;
...@@ -855,7 +855,7 @@ DBUS_SIGNAL( TrackListChangeSignal ) ...@@ -855,7 +855,7 @@ DBUS_SIGNAL( TrackListChangeSignal )
SIGNAL_INIT("TrackListChange"); SIGNAL_INIT("TrackListChange");
OUT_ARGUMENTS; OUT_ARGUMENTS;
playlist_t *p_playlist = pl_Yield( (vlc_object_t*) p_data ); playlist_t *p_playlist = pl_Hold( (vlc_object_t*) p_data );
dbus_int32_t i_elements = p_playlist->current.i_size; dbus_int32_t i_elements = p_playlist->current.i_size;
pl_Release( (vlc_object_t*) p_data ); pl_Release( (vlc_object_t*) p_data );
...@@ -996,7 +996,7 @@ static int TrackChange( vlc_object_t *p_this, const char *psz_var, ...@@ -996,7 +996,7 @@ static int TrackChange( vlc_object_t *p_this, const char *psz_var,
p_sys->b_meta_read = false; p_sys->b_meta_read = false;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
p_input = p_playlist->p_input; p_input = p_playlist->p_input;
if( !p_input ) if( !p_input )
...@@ -1035,7 +1035,7 @@ static int UpdateCaps( intf_thread_t* p_intf, bool b_playlist_locked ) ...@@ -1035,7 +1035,7 @@ static int UpdateCaps( intf_thread_t* p_intf, bool b_playlist_locked )
{ {
intf_sys_t* p_sys = p_intf->p_sys; intf_sys_t* p_sys = p_intf->p_sys;
dbus_int32_t i_caps = CAPS_CAN_HAS_TRACKLIST; dbus_int32_t i_caps = CAPS_CAN_HAS_TRACKLIST;
playlist_t* p_playlist = pl_Yield( p_intf ); playlist_t* p_playlist = pl_Hold( p_intf );
if( !b_playlist_locked ) PL_LOCK; if( !b_playlist_locked ) PL_LOCK;
if( p_playlist->current.i_size > 0 ) if( p_playlist->current.i_size > 0 )
...@@ -1160,7 +1160,7 @@ static int MarshalStatus( intf_thread_t* p_intf, DBusMessageIter* args, ...@@ -1160,7 +1160,7 @@ static int MarshalStatus( intf_thread_t* p_intf, DBusMessageIter* args,
playlist_t* p_playlist = NULL; playlist_t* p_playlist = NULL;
input_thread_t* p_input = NULL; input_thread_t* p_input = NULL;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
if( lock ) if( lock )
PL_LOCK; PL_LOCK;
......
...@@ -227,7 +227,7 @@ static void RunIntf( intf_thread_t *p_intf ) ...@@ -227,7 +227,7 @@ static void RunIntf( intf_thread_t *p_intf )
case GESTURE(RIGHT,LEFT,NONE,NONE): case GESTURE(RIGHT,LEFT,NONE,NONE):
{ {
input_thread_t * p_input; input_thread_t * p_input;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
p_input = input_from_playlist( p_playlist ); p_input = input_from_playlist( p_playlist );
vlc_object_release( p_playlist ); vlc_object_release( p_playlist );
...@@ -254,13 +254,13 @@ static void RunIntf( intf_thread_t *p_intf ) ...@@ -254,13 +254,13 @@ static void RunIntf( intf_thread_t *p_intf )
} }
break; break;
case GESTURE(LEFT,DOWN,NONE,NONE): case GESTURE(LEFT,DOWN,NONE,NONE):
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
playlist_Prev( p_playlist ); playlist_Prev( p_playlist );
vlc_object_release( p_playlist ); vlc_object_release( p_playlist );
break; break;
case GESTURE(RIGHT,DOWN,NONE,NONE): case GESTURE(RIGHT,DOWN,NONE,NONE):
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
playlist_Next( p_playlist ); playlist_Next( p_playlist );
vlc_object_release( p_playlist ); vlc_object_release( p_playlist );
...@@ -293,7 +293,7 @@ static void RunIntf( intf_thread_t *p_intf ) ...@@ -293,7 +293,7 @@ static void RunIntf( intf_thread_t *p_intf )
vlc_value_t val, list, list2; vlc_value_t val, list, list2;
int i_count, i; int i_count, i;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
p_input = input_from_playlist( p_playlist ); p_input = input_from_playlist( p_playlist );
...@@ -348,7 +348,7 @@ static void RunIntf( intf_thread_t *p_intf ) ...@@ -348,7 +348,7 @@ static void RunIntf( intf_thread_t *p_intf )
vlc_value_t val, list, list2; vlc_value_t val, list, list2;
int i_count, i; int i_count, i;
p_playlist = pl_Yield( p_intf ); p_playlist = pl_Hold( p_intf );
p_input = input_from_playlist( p_playlist ); p_input = input_from_playlist( p_playlist );
vlc_object_release( p_playlist ); vlc_object_release( p_playlist );
......
...@@ -149,7 +149,7 @@ static void Run( intf_thread_t *p_intf ) ...@@ -149,7 +149,7 @@ static void Run( intf_thread_t *p_intf )
vout_thread_t *p_vout = NULL; vout_thread_t *p_vout = NULL;
vlc_value_t val; vlc_value_t val;
int i; int i;
playlist_t *p_playlist = pl_Yield( p_intf ); playlist_t *p_playlist = pl_Hold( p_intf );
int canc = vlc_savecancel(); int canc = vlc_savecancel();
vlc_cleanup_push( __pl_Release, p_intf ); vlc_cleanup_push( __pl_Release, p_intf );
...@@ -947,7 +947,7 @@ static void PlayBookmark( intf_thread_t *p_intf, int i_num ) ...@@ -947,7 +947,7 @@ static void PlayBookmark( intf_thread_t *p_intf, int i_num )
{ {
vlc_value_t val; vlc_value_t val;
char psz_bookmark_name[11]; char psz_bookmark_name[11];
playlist_t *p_playlist = pl_Yield( p_intf ); playlist_t *p_playlist = pl_Hold( p_intf );
sprintf( psz_bookmark_name, "bookmark%i", i_num ); sprintf( psz_bookmark_name, "bookmark%i", i_num );
var_Create( p_intf, psz_bookmark_name, VLC_VAR_STRING|VLC_VAR_DOINHERIT ); var_Create( p_intf, psz_bookmark_name, VLC_VAR_STRING|VLC_VAR_DOINHERIT );
...@@ -973,7 +973,7 @@ static void PlayBookmark( intf_thread_t *p_intf, int i_num ) ...@@ -973,7 +973,7 @@ static void PlayBookmark( intf_thread_t *p_intf, int i_num )
static void SetBookmark( intf_thread_t *p_intf, int i_num ) static void SetBookmark( intf_thread_t *p_intf, int i_num )
{ {
playlist_t *p_playlist = pl_Yield( p_intf ); playlist_t *p_playlist = pl_Hold( p_intf );
char psz_bookmark_name[11]; char psz_bookmark_name[11];
sprintf( psz_bookmark_name, "bookmark%i", i_num ); sprintf( psz_bookmark_name, "bookmark%i", i_num );
var_Create( p_intf, psz_bookmark_name, var_Create( p_intf, psz_bookmark_name,
......
...@@ -128,7 +128,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -128,7 +128,7 @@ static int Open( vlc_object_t *p_this )
return( VLC_ENOMEM ); return( VLC_ENOMEM );
} }
p_sys->p_playlist = pl_Yield( p_this ); p_sys->p_playlist = pl_Hold( p_this );
p_sys->p_input = NULL; p_sys->p_input = NULL;
p_sys->p_vlm = NULL; p_sys->p_vlm = NULL;
p_sys->psz_address = psz_address; p_sys->psz_address = psz_address;
......
...@@ -506,7 +506,7 @@ static void Run( intf_thread_t *p_intf ) ...@@ -506,7 +506,7 @@ static void Run( intf_thread_t *p_intf )
FIND_ANYWHERE ); FIND_ANYWHERE );
if( p_input ) if( p_input )
{ {
p_playlist = pl_Yield( p_input ); p_playlist = pl_Hold( p_input );
} }
} }
/* New input has been registered */ /* New input has been registered */
...@@ -991,7 +991,7 @@ static int StateChanged( vlc_object_t *p_this, char const *psz_cmd, ...@@ -991,7 +991,7 @@ static int StateChanged( vlc_object_t *p_this, char const *psz_cmd,
p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT, FIND_ANYWHERE ); p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT, FIND_ANYWHERE );
if( p_input ) if( p_input )
{ {
p_playlist = pl_Yield( p_input ); p_playlist = pl_Hold( p_input );
char cmd[6];