diff options
author | Vittorio Gambaletta (VittGam) <ffmpeg-dev@vittgam.net> | 2016-01-26 15:13:09 +0100 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2016-01-26 17:36:08 +0100 |
commit | 74658a8b4db3a0b99e1461283d358f800e93f73a (patch) | |
tree | f464ccf2572183a755961176a3b13979f8af0777 /ffmpeg_opt.c | |
parent | 6e448fb97ee28f1d814de589881d5ddbb3b44013 (diff) | |
download | ffmpeg-74658a8b4db3a0b99e1461283d358f800e93f73a.tar.gz |
ffmpeg_opt: Allow -metadata option to set metadata on programs.
Signed-off-by: Vittorio Gambaletta <ffmpeg-dev@vittgam.net>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'ffmpeg_opt.c')
-rw-r--r-- | ffmpeg_opt.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ffmpeg_opt.c b/ffmpeg_opt.c index e03ad891d0..669976bcb0 100644 --- a/ffmpeg_opt.c +++ b/ffmpeg_opt.c @@ -2466,6 +2466,13 @@ loop_end: } m = &oc->chapters[index]->metadata; break; + case 'p': + if (index < 0 || index >= oc->nb_programs) { + av_log(NULL, AV_LOG_FATAL, "Invalid program index %d in metadata specifier.\n", index); + exit_program(1); + } + m = &oc->programs[index]->metadata; + break; default: av_log(NULL, AV_LOG_FATAL, "Invalid metadata specifier %s.\n", o->metadata[i].specifier); exit_program(1); |