summaryrefslogtreecommitdiff
path: root/libavformat/aviobuf.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2006-10-20 09:32:48 +0000
committerMichael Niedermayer <michaelni@gmx.at>2006-10-20 09:32:48 +0000
commit942f3bb528807df5f272a7577a2a3813fe18b848 (patch)
tree5799e010f078dc2df523f0b9704d4c53ddd14700 /libavformat/aviobuf.c
parentd3e7c5c35be22adb9964a25c434cf3f2f3ea816d (diff)
move memory reading ByteIOContext init from mov.c to avobuf.c
Originally committed as revision 6744 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/aviobuf.c')
-rw-r--r--libavformat/aviobuf.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavformat/aviobuf.c b/libavformat/aviobuf.c
index 80e8d084df..fe93546edd 100644
--- a/libavformat/aviobuf.c
+++ b/libavformat/aviobuf.c
@@ -54,6 +54,10 @@ int init_put_byte(ByteIOContext *s,
s->is_streamed = 0;
s->max_packet_size = 0;
s->update_checksum= NULL;
+ if(!read_packet && !write_flag){
+ s->pos = buffer_size;
+ s->buf_end = s->buffer + buffer_size;
+ }
return 0;
}