[FFmpeg-cvslog] avformat/flvdec: fix potential use of uninitialized variables
Michael Niedermayer
git at videolan.org
Mon Dec 15 15:25:06 CET 2014
ffmpeg | branch: release/2.5 | Michael Niedermayer <michaelni at gmx.at> | Wed Dec 10 13:30:51 2014 +0100| [0e4efad93c1defa12e8e2c103f7b92b91a7608dd] | committer: Michael Niedermayer
avformat/flvdec: fix potential use of uninitialized variables
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit 0fadbd3623cf9132832f48810c0edb93aa63f51b)
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0e4efad93c1defa12e8e2c103f7b92b91a7608dd
---
libavformat/flvdec.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c
index 17d1313..c64b3a9 100644
--- a/libavformat/flvdec.c
+++ b/libavformat/flvdec.c
@@ -459,11 +459,11 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream,
}
if (key) {
+ acodec = astream ? astream->codec : NULL;
+ vcodec = vstream ? vstream->codec : NULL;
+
// stream info doesn't live any deeper than the first object
if (depth == 1) {
- acodec = astream ? astream->codec : NULL;
- vcodec = vstream ? vstream->codec : NULL;
-
if (amf_type == AMF_DATA_TYPE_NUMBER ||
amf_type == AMF_DATA_TYPE_BOOL) {
if (!strcmp(key, "duration"))
More information about the ffmpeg-cvslog
mailing list