return NULL;
}
+
/* return a copy of the string */
vlc_mutex_lock( p_config->p_lock );
if( p_config->psz_value ) psz_value = strdup( p_config->psz_value );
p_config = config_FindConfig( p_this, psz_name );
+
/* sanity checks */
if( !p_config )
{
(p_config->i_type!=CONFIG_ITEM_FILE) &&
(p_config->i_type!=CONFIG_ITEM_DIRECTORY) &&
(p_config->i_type!=CONFIG_ITEM_MODULE_LIST) &&
+ (p_config->i_type!=CONFIG_ITEM_MODULE_CAT) &&
(p_config->i_type!=CONFIG_ITEM_MODULE_LIST_CAT) &&
(p_config->i_type!=CONFIG_ITEM_MODULE) )
{
case CONFIG_ITEM_FILE:
case CONFIG_ITEM_DIRECTORY:
case CONFIG_ITEM_MODULE:
+ case CONFIG_ITEM_MODULE_LIST:
+ case CONFIG_ITEM_MODULE_LIST_CAT:
+ case CONFIG_ITEM_MODULE_CAT:
config_PutPsz( p_this, psz_name, optarg );
break;
case CONFIG_ITEM_INTEGER:
case CONFIG_ITEM_FILE:
case CONFIG_ITEM_DIRECTORY:
case CONFIG_ITEM_MODULE:
+ case CONFIG_ITEM_MODULE_CAT:
+ case CONFIG_ITEM_MODULE_LIST:
+ case CONFIG_ITEM_MODULE_LIST_CAT:
config_PutPsz( p_this, pp_shortopts[i_cmd]->psz_name, optarg );
break;
case CONFIG_ITEM_INTEGER:
p_view->p_root,
p_playlist->request.p_node,
p_new );
- if( p_new == NULL ) break;
+ if( p_new == NULL )
+ {
+ if( b_loop )
+ {
+ p_new = playlist_FindNextFromParent( p_playlist,
+ p_playlist->request.i_view,
+ p_view->p_root,
+ p_playlist->request.p_node,
+ NULL );
+ if( p_new == NULL ) break;
+ }
+ else
+ {
+ break;
+ }
+ }
}
}
else if( i_skip < 0 )
else
{
msg_Dbg( p_playlist,"finished" );
- p_new = NULL;
+ if( b_loop && p_playlist->i_size > 0)
+ {
+ p_playlist->i_index = 0;
+ p_new = p_playlist->pp_items[0];
+ }
+ else
+ p_new = NULL;
}
}
/* We are playing with a view */
p_view->p_root,
p_playlist->status.p_node,
p_playlist->status.p_item );
+ if( p_new == NULL && b_loop )
+ {
+ p_new = playlist_FindNextFromParent( p_playlist,
+ p_playlist->status.i_view,
+ p_view->p_root,
+ p_playlist->status.p_node,
+ NULL );
+ }
}
}
msg_Dbg(p_playlist,"next item found in "I64Fi " us", mdate()-start );
#endif
- if( p_new == NULL ) { msg_Info( p_playlist, "Nothing to play" ); }
-
+ if( p_new == NULL )
+ {
+ msg_Info( p_playlist, "Nothing to play" );
+ }
return p_new;
}