summaryrefslogtreecommitdiffstats
path: root/ffmpeg.c
diff options
context:
space:
mode:
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index 7d5a66f..6df63d0 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1490,7 +1490,9 @@ int find_codec_parameters(AVFormatContext *ic)
ret = -1;
goto the_end;
}
- avcodec_open(&st->codec, codec);
+ ret = avcodec_open(&st->codec, codec);
+ if (ret < 0)
+ goto the_end;
}
}
pktl = av_mallocz(sizeof(AVPacketList));
OpenPOWER on IntegriCloud