Mercurial > libavformat.hg
diff libnut.c @ 2771:d52c718e83f9 libavformat
Use dynamically allocated ByteIOContext in AVFormatContext
patch by: Bj?rn Axelsson, bjorn d axelsson a intinor d se
thread: [PATCH] Remove static ByteIOContexts, 06 nov 2007
| author | andoma |
|---|---|
| date | Wed, 21 Nov 2007 07:41:00 +0000 |
| parents | 53b9a531f490 |
| children | 7a0230981402 |
line wrap: on
line diff
--- a/libnut.c Mon Nov 19 20:28:11 2007 +0000 +++ b/libnut.c Wed Nov 21 07:41:00 2007 +0000 @@ -54,7 +54,7 @@ static int nut_write_header(AVFormatContext * avf) { NUTContext * priv = avf->priv_data; - ByteIOContext * bc = &avf->pb; + ByteIOContext * bc = avf->pb; nut_muxer_opts_t mopts = { .output = { .priv = bc, @@ -137,7 +137,7 @@ } static int nut_write_trailer(AVFormatContext * avf) { - ByteIOContext * bc = &avf->pb; + ByteIOContext * bc = avf->pb; NUTContext * priv = avf->priv_data; int i; @@ -187,7 +187,7 @@ static int nut_read_header(AVFormatContext * avf, AVFormatParameters * ap) { NUTContext * priv = avf->priv_data; - ByteIOContext * bc = &avf->pb; + ByteIOContext * bc = avf->pb; nut_demuxer_opts_t dopts = { .input = { .priv = bc, @@ -272,7 +272,7 @@ if (pd.flags & NUT_FLAG_KEY) pkt->flags |= PKT_FLAG_KEY; pkt->pts = pd.pts; pkt->stream_index = pd.stream; - pkt->pos = url_ftell(&avf->pb); + pkt->pos = url_ftell(avf->pb); ret = nut_read_frame(priv->nut, &pd.len, pkt->data);
