diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2007-03-11 05:51:06 +0300 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2007-03-11 05:51:06 +0300 |
commit | e1315fb1607aac61463102c45d51099c813689ad (patch) | |
tree | a31664757d2999eae3ba6e1560bfa2bad243a093 /libavformat/asf-enc.c | |
parent | 050aa8b9bca6a2c29e1c4c914e05aca49007f1d7 (diff) |
some url_is_streamed()==1 related fixes
Originally committed as revision 8319 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/asf-enc.c')
-rw-r--r-- | libavformat/asf-enc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavformat/asf-enc.c b/libavformat/asf-enc.c index fa3a9b2945..f1d9c69034 100644 --- a/libavformat/asf-enc.c +++ b/libavformat/asf-enc.c @@ -311,7 +311,7 @@ static int asf_write_header1(AVFormatContext *s, int64_t file_size, int64_t data put_le64(pb, duration); /* end time stamp (in 100ns units) */ put_le64(pb, asf->duration); /* duration (in 100ns units) */ put_le64(pb, PREROLL_TIME); /* start time stamp */ - put_le32(pb, asf->is_streamed ? 3 : 2); /* ??? */ + put_le32(pb, (asf->is_streamed || url_is_streamed(pb)) ? 3 : 2); /* ??? */ put_le32(pb, asf->packet_size); /* packet size */ put_le32(pb, asf->packet_size); /* packet size */ put_le32(pb, bit_rate); /* Nominal data rate in bps */ @@ -498,7 +498,7 @@ static int asf_write_header(AVFormatContext *s) asf->nb_index_count = 0; asf->maximum_packet = 0; - if (asf_write_header1(s, 0, 50) < 0) { + if (asf_write_header1(s, 0, 0) < 0) { //av_free(asf); return -1; } @@ -796,7 +796,7 @@ static int asf_write_trailer(AVFormatContext *s) } put_flush_packet(&s->pb); - if (asf->is_streamed) { + if (asf->is_streamed || url_is_streamed(&s->pb)) { put_chunk(s, 0x4524, 0, 0); /* end of stream */ } else { /* rewrite an updated header */ |