OSDN Git Service
(root)
/
coroid
/
libav_saccubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6bbdba0
)
Fix assertion fail on audio files with invalid sample rates,
author
Daniel Kang
<daniel.d.kang@gmail.com>
Thu, 6 Jan 2011 03:30:19 +0000
(
03:30
+0000)
committer
Carl Eugen Hoyos
<cehoyos@rainbow.studorg.tuwien.ac.at>
Thu, 6 Jan 2011 03:30:19 +0000
(
03:30
+0000)
fixes issue 2475.
Patch by Daniel Kang, daniel.d.kang at gmail
Originally committed as revision 26240 to svn://svn.ffmpeg.org/ffmpeg/trunk
libavformat/utils.c
patch
|
blob
|
history
diff --git
a/libavformat/utils.c
b/libavformat/utils.c
index
fb93e3b
..
32067e9
100644
(file)
--- a/
libavformat/utils.c
+++ b/
libavformat/utils.c
@@
-812,7
+812,7
@@
static void compute_frame_duration(int *pnum, int *pden, AVStream *st,
break;
case AVMEDIA_TYPE_AUDIO:
frame_size = get_audio_frame_size(st->codec, pkt->size);
- if (frame_size < 0)
+ if (frame_size <
= 0 || st->codec->sample_rate <=
0)
break;
*pnum = frame_size;
*pden = st->codec->sample_rate;