[FFmpeg-devel] [PATCH 2/3] libnut: Check nut_demuxer_init() return value.
Michael Niedermayer
michaelni at gmx.at
Wed Dec 7 23:38:17 CET 2011
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
---
libavformat/libnut.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/libavformat/libnut.c b/libavformat/libnut.c
index 9f64544..be0328a 100644
--- a/libavformat/libnut.c
+++ b/libavformat/libnut.c
@@ -207,6 +207,9 @@ static int nut_read_header(AVFormatContext * avf, AVFormatParameters * ap) {
nut_stream_header_tt * s;
int ret, i;
+ if(!nut)
+ return -1;
+
if ((ret = nut_read_headers(nut, &s, NULL))) {
av_log(avf, AV_LOG_ERROR, " NUT error: %s\n", nut_error(ret));
nut_demuxer_uninit(nut);
--
1.7.5.4
More information about the ffmpeg-devel
mailing list