[vlc-commits] Use TAB_INSERT instead of INSERT_ELEM
Rémi Denis-Courmont
git at videolan.org
Thu May 18 20:22:05 CEST 2017
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu May 18 20:54:10 2017 +0300| [53b4a1469fa85a3999670807d25d7afd85af0f48] | committer: Rémi Denis-Courmont
Use TAB_INSERT instead of INSERT_ELEM
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=53b4a1469fa85a3999670807d25d7afd85af0f48
---
src/input/stats.c | 3 +--
src/playlist/item.c | 4 ++--
src/playlist/tree.c | 6 ++----
3 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/src/input/stats.c b/src/input/stats.c
index e406a657cb..c76227a5ee 100644
--- a/src/input/stats.c
+++ b/src/input/stats.c
@@ -181,8 +181,7 @@ void stats_Update( counter_t *p_counter, uint64_t val, uint64_t *new_val )
p_new->value = val;
p_new->date = p_counter->last_update;
- INSERT_ELEM( p_counter->pp_samples, p_counter->i_samples,
- 0, p_new );
+ TAB_INSERT(p_counter->i_samples, p_counter->pp_samples, p_new, 0);
if( p_counter->i_samples == 3 )
{
diff --git a/src/playlist/item.c b/src/playlist/item.c
index 5616ad2181..130a4d9383 100644
--- a/src/playlist/item.c
+++ b/src/playlist/item.c
@@ -616,7 +616,7 @@ int playlist_TreeMove( playlist_t * p_playlist, playlist_item_t *p_item,
if( p_detach == p_node && i_index < i_newpos )
i_newpos--;
- INSERT_ELEM( p_node->pp_children, p_node->i_children, i_newpos, p_item );
+ TAB_INSERT(p_node->i_children, p_node->pp_children, p_item, i_newpos);
p_item->p_parent = p_node;
pl_priv( p_playlist )->b_reset_currently_playing = true;
@@ -655,7 +655,7 @@ int playlist_TreeMoveMany( playlist_t *p_playlist,
for( int i = i_items - 1; i >= 0; i-- )
{
playlist_item_t *p_item = pp_items[i];
- INSERT_ELEM( p_node->pp_children, p_node->i_children, i_newpos, p_item );
+ TAB_INSERT(p_node->i_children, p_node->pp_children, p_item, i_newpos);
p_item->p_parent = p_node;
}
diff --git a/src/playlist/tree.c b/src/playlist/tree.c
index 5bce6ae0dc..12e4154025 100644
--- a/src/playlist/tree.c
+++ b/src/playlist/tree.c
@@ -152,10 +152,8 @@ int playlist_NodeInsert( playlist_item_t *p_parent, playlist_item_t *p_item,
if( i_position == -1 ) i_position = p_parent->i_children ;
assert( i_position <= p_parent->i_children);
- INSERT_ELEM( p_parent->pp_children,
- p_parent->i_children,
- i_position,
- p_item );
+ TAB_INSERT(p_parent->i_children, p_parent->pp_children,
+ p_item, i_position);
p_item->p_parent = p_parent;
/* Inherit special flags from parent (sd cases) */
More information about the vlc-commits
mailing list