mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-03-28 12:32:17 +02:00
avconv: fix off by one check in complex_filter
nb_input_files is already an invalid index.
This commit is contained in:
parent
269cb6751b
commit
1381081cdb
2
avconv.c
2
avconv.c
@ -725,7 +725,7 @@ static void init_input_filter(FilterGraph *fg, AVFilterInOut *in)
|
|||||||
char *p;
|
char *p;
|
||||||
int file_idx = strtol(in->name, &p, 0);
|
int file_idx = strtol(in->name, &p, 0);
|
||||||
|
|
||||||
if (file_idx < 0 || file_idx > nb_input_files) {
|
if (file_idx < 0 || file_idx >= nb_input_files) {
|
||||||
av_log(NULL, AV_LOG_FATAL, "Invalid file index %d in filtegraph description %s.\n",
|
av_log(NULL, AV_LOG_FATAL, "Invalid file index %d in filtegraph description %s.\n",
|
||||||
file_idx, fg->graph_desc);
|
file_idx, fg->graph_desc);
|
||||||
exit_program(1);
|
exit_program(1);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user