diff options
author | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2009-03-20 01:23:33 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2009-03-20 01:23:33 +0000 |
commit | b9edbe9953d43b1bfff6ed5ffe8e615289a5d944 (patch) | |
tree | 2f4d7b10c7f9b31f384af63b0490125779d50919 /libavformat/ffmenc.c | |
parent | cf16c17a69be7f665c9d465e0ce29a1aa9d5783c (diff) | |
download | ffmpeg-b9edbe9953d43b1bfff6ed5ffe8e615289a5d944.tar.gz |
do not write ffm write index by default, detect if file is being written and return EOF
Originally committed as revision 18063 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/ffmenc.c')
-rw-r--r-- | libavformat/ffmenc.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/libavformat/ffmenc.c b/libavformat/ffmenc.c index 9a55264b44..3de4984dfe 100644 --- a/libavformat/ffmenc.c +++ b/libavformat/ffmenc.c @@ -93,8 +93,7 @@ static int ffm_write_header(AVFormatContext *s) /* header */ put_le32(pb, MKTAG('F', 'F', 'M', '1')); put_be32(pb, ffm->packet_size); - /* XXX: store write position in other file ? */ - put_be64(pb, ffm->packet_size); /* current write position */ + put_be64(pb, 0); /* current write position */ put_be32(pb, s->nb_streams); bit_rate = 0; @@ -224,15 +223,6 @@ static int ffm_write_trailer(AVFormatContext *s) put_flush_packet(pb); - if (!url_is_streamed(pb)) { - int64_t size; - /* update the write offset */ - size = url_ftell(pb); - url_fseek(pb, 8, SEEK_SET); - put_be64(pb, size); - put_flush_packet(pb); - } - return 0; } |