- strcpy( psz_absolute, p_demux->psz_access );
- strcat( psz_absolute, "://" );
- strncat( psz_absolute, p_demux->psz_path, i_len);
- }
- else
- {
- strcpy( psz_absolute, "" );
- }
- strcat( psz_absolute, psz_ref );
- msg_Dbg( p_demux, "adding ref = `%s'", psz_absolute );
- if( p_item )
- {
- playlist_item_t *p_child =
- playlist_ItemNew( p_playlist,
- psz_absolute,
- psz_absolute );
- if( p_child )
- {
- playlist_NodeAddItem( p_playlist, p_child,
- p_item->pp_parents[0]->i_view,
- p_item, PLAYLIST_APPEND,
- PLAYLIST_END );
- playlist_CopyParents( p_item, p_child );
- b_play = VLC_TRUE;
- }
- }
-#ifndef HAVE_ALLOCA
- free( psz_absolute );
-#endif
+ psz_ref = psz_absolute;
+ free( psz_path );
+ }
+ if( p_current )
+ {
+ input_item_t *p_input;
+ msg_Dbg( p_demux, "adding ref = `%s'", psz_ref );
+ p_input = input_ItemNewExt( p_playlist, psz_ref, NULL,
+ 0, NULL, -1 );
+ input_ItemCopyOptions( p_current->p_input, p_input );
+ playlist_BothAddInput( p_playlist, p_input,
+ p_item_in_category,
+ PLAYLIST_APPEND, PLAYLIST_END,
+ NULL, NULL);