diff options
author | Måns Rullgård <mans@mansr.com> | 2005-04-09 23:27:48 +0000 |
---|---|---|
committer | Måns Rullgård <mans@mansr.com> | 2005-04-09 23:27:48 +0000 |
commit | ad3aa8745633e162cd1b79fbbaba44bc34af9b58 (patch) | |
tree | 81799fb849e13d403d21238cc3bd04f4a8957c9f /libavformat | |
parent | a0a74ad9f0f18b276b0f3581c533f19e598b7eac (diff) | |
download | ffmpeg-ad3aa8745633e162cd1b79fbbaba44bc34af9b58.tar.gz |
pre-c99 compatibility
Originally committed as revision 4116 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/ogg2.c | 2 | ||||
-rw-r--r-- | libavformat/ogg2.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/ogg2.c b/libavformat/ogg2.c index c54b2a04c5..065d3bc0a6 100644 --- a/libavformat/ogg2.c +++ b/libavformat/ogg2.c @@ -80,7 +80,7 @@ ogg_save (AVFormatContext * s) { ogg_t *ogg = s->priv_data; ogg_state_t *ost = - av_malloc(sizeof (*ost) + ogg->nstreams * sizeof (*ogg->streams)); + av_malloc(sizeof (*ost) + (ogg->nstreams-1) * sizeof (*ogg->streams)); int i; ost->pos = url_ftell (&s->pb);; ost->curidx = ogg->curidx; diff --git a/libavformat/ogg2.h b/libavformat/ogg2.h index b1146e314c..f397a57197 100644 --- a/libavformat/ogg2.h +++ b/libavformat/ogg2.h @@ -55,7 +55,7 @@ typedef struct ogg_state { uint64_t pos; int curidx; struct ogg_state *next; - ogg_stream_t streams[]; + ogg_stream_t streams[1]; } ogg_state_t; typedef struct ogg { |