diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-01-06 19:51:38 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-01-06 20:37:53 +0100 |
commit | 81bdaacb6556e4c70fddfe67a828b8f29ea65ea8 (patch) | |
tree | 7130787ac5be72c76e82892457c58949a12e9534 /libavformat/mov.c | |
parent | 3e3193f03c7d0b331c91040d7659b0248c4ec221 (diff) | |
download | ffmpeg-81bdaacb6556e4c70fddfe67a828b8f29ea65ea8.tar.gz |
avformat/mov: Fix mixed declaration and statement warning
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit db27f50e0658e91758e8a17fdcf390e6bc93c1d2)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/mov.c')
-rw-r--r-- | libavformat/mov.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c index 97ef0963b3..294a8b0cb5 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -279,10 +279,11 @@ static int mov_read_covr(MOVContext *c, AVIOContext *pb, int type, int len) static int mov_metadata_raw(MOVContext *c, AVIOContext *pb, unsigned len, const char *key) { + char *value; // Check for overflow. if (len >= INT_MAX) return AVERROR(EINVAL); - char *value = av_malloc(len + 1); + value = av_malloc(len + 1); if (!value) return AVERROR(ENOMEM); avio_read(pb, value, len); |