aboutsummaryrefslogtreecommitdiffstats
path: root/avconv_opt.c
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2014-12-17 14:53:45 +0100
committerVittorio Giovara <vittorio.giovara@gmail.com>2014-12-18 23:27:14 +0100
commitb1306823d0b3ae998c8e10ad832004eb13bdd93e (patch)
tree2e7642dc896d7f19682f50b913ab5b5be57b83ac /avconv_opt.c
parent9745f19ffc9031ce480e43d7cf1053b58100d70f (diff)
downloadffmpeg-b1306823d0b3ae998c8e10ad832004eb13bdd93e.tar.gz
check memory errors from av_strdup()
Diffstat (limited to 'avconv_opt.c')
-rw-r--r--avconv_opt.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/avconv_opt.c b/avconv_opt.c
index 6d43bc1609..74e235b6d5 100644
--- a/avconv_opt.c
+++ b/avconv_opt.c
@@ -213,6 +213,8 @@ static int opt_map(void *optctx, const char *opt, const char *arg)
arg++;
}
map = av_strdup(arg);
+ if (!map)
+ return AVERROR(ENOMEM);
/* parse sync stream first, just pick first matching stream */
if (sync = strchr(map, ',')) {