+ params->psz_category );
+}
+
+/*****************************************************************************
+ * CreateInputItemFromShoutItem:
+ *****************************************************************************/
+static input_item_t * CreateInputItemFromShoutItem( services_discovery_t *p_sd,
+ const struct shout_item_t * p_item )
+{
+ int i;
+ /* Create the item */
+ input_item_t *p_input = input_item_New( p_sd, p_item->psz_url,
+ vlc_gettext(p_item->psz_name) );
+
+ /* Copy options */
+ for( i = 0; p_item->ppsz_options[i] != NULL; i++ )
+ input_item_AddOption( p_input, p_item->ppsz_options[i], VLC_INPUT_OPTION_TRUSTED );
+ input_item_AddOption( p_input, "no-playlist-autostart", VLC_INPUT_OPTION_TRUSTED );
+
+ return p_input;
+}
+
+/*****************************************************************************
+ * AddSubitemsOfShoutItemURL:
+ *****************************************************************************/
+static void AddSubitemsOfShoutItemURL( services_discovery_t *p_sd,
+ const struct shout_item_t * p_item,
+ const char * psz_category )
+{
+ struct shout_category_t category = { p_sd, psz_category };
+
+ /* Create the item */
+ input_item_t *p_input = CreateInputItemFromShoutItem( p_sd, p_item );
+
+ /* Read every subitems, and add them in ItemAdded */
+ vlc_event_attach( &p_input->event_manager, vlc_InputItemSubItemAdded,
+ ItemAdded, &category );
+ input_Read( p_sd, p_input, true );
+ vlc_event_detach( &p_input->event_manager, vlc_InputItemSubItemAdded,
+ ItemAdded, &category );
+
+ vlc_gc_decref( p_input );