vlc | branch: master | Pierre Lamot <[email protected]> | Mon Oct 21 18:08:53 2019 +0200| [df3ca174aeae5672a39d81e3c497c0799a293634] | committer: Jean-Baptiste Kempf
input: also copy input slaves in input_item_Copy Signed-off-by: Jean-Baptiste Kempf <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=df3ca174aeae5672a39d81e3c497c0799a293634 --- src/input/item.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/input/item.c b/src/input/item.c index fbd74cc95f..9c3442d5c7 100644 --- a/src/input/item.c +++ b/src/input/item.c @@ -1119,6 +1119,22 @@ input_item_t *input_item_Copy( input_item_t *p_input ) vlc_meta_Merge( meta, p_input->p_meta ); } b_net = p_input->b_net; + + if( likely(item != NULL) && p_input->i_slaves > 0 ) + { + for( int i = 0; i < p_input->i_slaves; i++ ) + { + input_item_slave_t* slave = input_item_slave_New( + p_input->pp_slaves[i]->psz_uri, + p_input->pp_slaves[i]->i_type, + p_input->pp_slaves[i]->i_priority); + if( unlikely(slave != NULL) ) + { + TAB_APPEND(item->i_slaves, item->pp_slaves, slave); + } + } + } + vlc_mutex_unlock( &p_input->lock ); if( likely(item != NULL) ) _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
