@ -1001,14 +1001,14 @@ static void matroska_convert_tag(AVFormatContext *s, EbmlList *list,
if ( prefix ) snprintf ( key , sizeof ( key ) , " %s/%s " , prefix , tags [ i ] . name ) ;
else av_strlcpy ( key , tags [ i ] . name , sizeof ( key ) ) ;
if ( tags [ i ] . def | | ! lang ) {
av_metadata_set ( metadata , key , tags [ i ] . string ) ;
av_metadata_set2 ( metadata , key , tags [ i ] . string , 0 ) ;
if ( tags [ i ] . sub . nb_elem )
matroska_convert_tag ( s , & tags [ i ] . sub , metadata , key ) ;
}
if ( lang ) {
av_strlcat ( key , " - " , sizeof ( key ) ) ;
av_strlcat ( key , lang , sizeof ( key ) ) ;
av_metadata_set ( metadata , key , tags [ i ] . string ) ;
av_metadata_set2 ( metadata , key , tags [ i ] . string , 0 ) ;
if ( tags [ i ] . sub . nb_elem )
matroska_convert_tag ( s , & tags [ i ] . sub , metadata , key ) ;
}
@ -1157,7 +1157,7 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap)
if ( matroska - > duration )
matroska - > ctx - > duration = matroska - > duration * matroska - > time_scale
* 1000 / AV_TIME_BASE ;
av_metadata_set ( & s - > metadata , " title " , matroska - > title ) ;
av_metadata_set2 ( & s - > metadata , " title " , matroska - > title , 0 ) ;
tracks = matroska - > tracks . elem ;
for ( i = 0 ; i < matroska - > tracks . nb_elem ; i + + ) {
@ -1352,8 +1352,8 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap)
st - > codec - > codec_id = codec_id ;
st - > start_time = 0 ;
if ( strcmp ( track - > language , " und " ) )
av_metadata_set ( & st - > metadata , " language " , track - > language ) ;
av_metadata_set ( & st - > metadata , " title " , track - > name ) ;
av_metadata_set2 ( & st - > metadata , " language " , track - > language , 0 ) ;
av_metadata_set2 ( & st - > metadata , " title " , track - > name , 0 ) ;
if ( track - > flag_default )
st - > disposition | = AV_DISPOSITION_DEFAULT ;
@ -1410,7 +1410,7 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap)
AVStream * st = av_new_stream ( s , 0 ) ;
if ( st = = NULL )
break ;
av_metadata_set ( & st - > metadata , " filename " , attachements [ j ] . filename ) ;
av_metadata_set2 ( & st - > metadata , " filename " , attachements [ j ] . filename , 0 ) ;
st - > codec - > codec_id = CODEC_ID_NONE ;
st - > codec - > codec_type = AVMEDIA_TYPE_ATTACHMENT ;
st - > codec - > extradata = av_malloc ( attachements [ j ] . bin . size ) ;
@ -1438,8 +1438,8 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap)
ff_new_chapter ( s , chapters [ i ] . uid , ( AVRational ) { 1 , 1000000000 } ,
chapters [ i ] . start , chapters [ i ] . end ,
chapters [ i ] . title ) ;
av_metadata_set ( & chapters [ i ] . chapter - > metadata ,
" title " , chapters [ i ] . title ) ;
av_metadata_set2 ( & chapters [ i ] . chapter - > metadata ,
" title " , chapters [ i ] . title , 0 ) ;
max_start = chapters [ i ] . start ;
}