OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
af32a1f
)
ffmpeg: check timebase validity before using it.
author
Michael Niedermayer
<michaelni@gmx.at>
Mon, 15 Oct 2012 18:35:01 +0000
(20:35 +0200)
committer
Michael Niedermayer
<michaelni@gmx.at>
Mon, 15 Oct 2012 18:35:45 +0000
(20:35 +0200)
Found-by: Daemon404
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
ffmpeg_filter.c
patch
|
blob
|
history
diff --git
a/ffmpeg_filter.c
b/ffmpeg_filter.c
index
d0f25d8
..
0a3b2cd
100644
(file)
--- a/
ffmpeg_filter.c
+++ b/
ffmpeg_filter.c
@@
-561,7
+561,7
@@
static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
if (!ist->framerate.num) {
AVRational codec_fr = av_inv_q(ist->st->codec->time_base);
codec_fr.den *= ist->st->codec->ticks_per_frame;
- if(av_q2d(codec_fr) < av_q2d(fr)*0.7)
+ if(
codec_fr.num>0 && codec_fr.den>0 &&
av_q2d(codec_fr) < av_q2d(fr)*0.7)
fr = codec_fr;
}