Commit 4f2f1d8e authored by Rafaël Carré's avatar Rafaël Carré

playlist_NodeInsert(): adds an assertion

parent 835f1233
...@@ -208,6 +208,7 @@ int playlist_NodeInsert( playlist_t *p_playlist, ...@@ -208,6 +208,7 @@ int playlist_NodeInsert( playlist_t *p_playlist,
(void)p_playlist; (void)p_playlist;
assert( p_parent && p_parent->i_children != -1 ); assert( p_parent && p_parent->i_children != -1 );
if( i_position == -1 ) i_position = p_parent->i_children ; if( i_position == -1 ) i_position = p_parent->i_children ;
assert( i_position <= p_parent->i_children);
INSERT_ELEM( p_parent->pp_children, INSERT_ELEM( p_parent->pp_children,
p_parent->i_children, p_parent->i_children,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment