vsrc_testsrc: Fix case without a specified duration

Fixes regression since 98f753ec51

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2012-09-21 03:00:15 +02:00
parent cc07a7925e
commit 3dc24600ba

View File

@ -109,6 +109,7 @@ static av_cold int init(AVFilterContext *ctx, const char *args)
return ret;
}
test->duration = -1;
if (test->duration_str &&
(ret = av_parse_time(&test->duration, test->duration_str, 1)) < 0) {
av_log(ctx, AV_LOG_ERROR, "Invalid duration: '%s'\n", test->duration_str);