[vlc-devel] [PATCH 03/40] playlist: remove playlist_ItemFindFromInputAndRoot

RĂ©mi Denis-Courmont remi at remlab.net
Sun May 14 17:45:33 CEST 2017


This is no longer used.
---
 src/playlist/item.c              | 30 ------------------------------
 src/playlist/playlist_internal.h |  3 ---
 2 files changed, 33 deletions(-)

diff --git a/src/playlist/item.c b/src/playlist/item.c
index 97d1433aff..6f090f2899 100644
--- a/src/playlist/item.c
+++ b/src/playlist/item.c
@@ -592,36 +592,6 @@ int playlist_InsertInputItemTree (
  * Playlist item misc operations
  *****************************************************************************/
 
-/**
- * Find an item within a root, given its input id.
- *
- * \param p_playlist the playlist object
- * \param p_item the input item
- * \param p_root root playlist item
- * \return the first found item, or NULL if not found
- */
-playlist_item_t *playlist_ItemFindFromInputAndRoot( playlist_t *p_playlist,
-                                                    input_item_t *p_item,
-                                                    playlist_item_t *p_root )
-{
-    for( int i = 0 ; i< p_root->i_children ; i++ )
-    {
-        if( p_root->pp_children[i]->p_input == p_item )
-        {
-            return p_root->pp_children[i];
-        }
-        else if( p_root->pp_children[i]->i_children >= 0 )
-        {
-            playlist_item_t *p_search =
-                 playlist_ItemFindFromInputAndRoot( p_playlist, p_item,
-                                                    p_root->pp_children[i] );
-            if( p_search ) return p_search;
-        }
-    }
-    return NULL;
-}
-
-
 static int ItemIndex ( playlist_item_t *p_item )
 {
     int idx;
diff --git a/src/playlist/playlist_internal.h b/src/playlist/playlist_internal.h
index 6aa7209023..8d0daa4352 100644
--- a/src/playlist/playlist_internal.h
+++ b/src/playlist/playlist_internal.h
@@ -127,9 +127,6 @@ int playlist_InsertInputItemTree ( playlist_t *,
 int playlist_NodeInsert(playlist_t *, playlist_item_t*, playlist_item_t *,
                         int);
 
-playlist_item_t *playlist_ItemFindFromInputAndRoot( playlist_t *p_playlist,
-                              input_item_t *p_input, playlist_item_t *p_root );
-
 void playlist_ItemRelease( playlist_t *, playlist_item_t * );
 
 void ResetCurrentlyPlaying( playlist_t *p_playlist, playlist_item_t *p_cur );
-- 
2.11.0



More information about the vlc-devel mailing list