diff options
author | Aurelien Jacobs <aurel@gnuage.org> | 2009-02-26 22:35:26 +0000 |
---|---|---|
committer | Aurelien Jacobs <aurel@gnuage.org> | 2009-02-26 22:35:26 +0000 |
commit | 0d2e86d7aee94aed5205bc9b8a031b2d5a78bb76 (patch) | |
tree | cca474e1a687176ce0ea6f73ed5458b51d5c08b0 /libavformat/wc3movie.c | |
parent | 3f4c2bf99be6ab69da3bad021156b1dc16c57900 (diff) | |
download | ffmpeg-0d2e86d7aee94aed5205bc9b8a031b2d5a78bb76.tar.gz |
use new metadata API in wc3 demuxer
Originally committed as revision 17627 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/wc3movie.c')
-rw-r--r-- | libavformat/wc3movie.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libavformat/wc3movie.c b/libavformat/wc3movie.c index 6f7f49d76a..6d7592f070 100644 --- a/libavformat/wc3movie.c +++ b/libavformat/wc3movie.c @@ -132,6 +132,7 @@ static int wc3_read_header(AVFormatContext *s, unsigned int size; AVStream *st; unsigned char preamble[WC3_PREAMBLE_SIZE]; + char buffer[513]; int ret = 0; int current_palette = 0; int bytes_to_read; @@ -185,8 +186,10 @@ static int wc3_read_header(AVFormatContext *s, bytes_to_read = size; else bytes_to_read = 512; - if ((ret = get_buffer(pb, s->title, bytes_to_read)) != bytes_to_read) + if ((ret = get_buffer(pb, buffer, bytes_to_read)) != bytes_to_read) return AVERROR(EIO); + buffer[bytes_to_read] = 0; + av_metadata_set(&s->metadata, "title", buffer); break; case SIZE_TAG: |