diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-02-05 22:57:35 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-02-05 22:57:35 +0100 |
commit | f0eacbc760c8b27c2064cea5395e32971853c73c (patch) | |
tree | 930cc93002da3866d025d0cd1f7538837bd98748 /libavformat | |
parent | b0635e2fcf80717dd618ef75d3317d62ed85c300 (diff) | |
download | ffmpeg-streaming-f0eacbc760c8b27c2064cea5395e32971853c73c.zip ffmpeg-streaming-f0eacbc760c8b27c2064cea5395e32971853c73c.tar.gz |
dvenc: dont fail hard if the timecode is invalid
Instead just dont store the timecode
Fixes Ticket2187
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/dvenc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/dvenc.c b/libavformat/dvenc.c index 0841d0e..0b3811e 100644 --- a/libavformat/dvenc.c +++ b/libavformat/dvenc.c @@ -376,8 +376,8 @@ static int dv_write_header(AVFormatContext *s) break; } } - if (tcr) - return av_timecode_init_from_string(&dvc->tc, rate, tcr->value, s); + if (tcr && av_timecode_init_from_string(&dvc->tc, rate, tcr->value, s) >= 0) + return 0; return av_timecode_init(&dvc->tc, rate, 0, 0, s); } |