Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Bœsch <u@pkh.me>2014-04-27 13:49:13 +0400
committerClément Bœsch <u@pkh.me>2014-04-27 13:49:13 +0400
commitb2cfd1fde7a2643be9978ec8da58c184a5d9a140 (patch)
treeb36586fee4c7658161d68722ac3bc9fa9e2df4c4 /libavfilter/vf_curves.c
parentb4329605289e25bb071ec1c1182bf25fc83b09aa (diff)
avfilter/curves: fix resource leaks.
Fixes CID1206650
Diffstat (limited to 'libavfilter/vf_curves.c')
-rw-r--r--libavfilter/vf_curves.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavfilter/vf_curves.c b/libavfilter/vf_curves.c
index 93799b0b1d..b17c391fff 100644
--- a/libavfilter/vf_curves.c
+++ b/libavfilter/vf_curves.c
@@ -331,8 +331,10 @@ static int parse_psfile(AVFilterContext *ctx, const char *fname)
return ret;
#define READ16(dst) do { \
- if (size < 2) \
- return AVERROR_INVALIDDATA; \
+ if (size < 2) { \
+ ret = AVERROR_INVALIDDATA; \
+ goto end; \
+ } \
dst = AV_RB16(buf); \
buf += 2; \
size -= 2; \