1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-24 13:56:33 +02:00
FFmpeg/libavcodec
James Almer a4a3fd814a avcodec/utils: don't return negative values in av_get_audio_frame_duration()
In some extrme cases, like with adpcm_ms samples with an extremely high channel
count, get_audio_frame_duration() may return a negative frame duration value.
Don't propagate it, and instead return 0, signaling that a duration could not
be determined.

Fixes ticket #9312

Signed-off-by: James Almer <jamrial@gmail.com>
(cherry picked from commit e01d306c647b5827102260b885faa223b646d2d1)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2021-09-12 11:22:04 +02:00
..
2021-09-11 21:23:49 +02:00
2020-07-03 00:03:44 +02:00
2021-09-11 21:23:48 +02:00
2019-11-14 23:30:37 +01:00
2021-09-11 21:23:48 +02:00
2019-11-15 12:25:45 +01:00
2020-07-02 19:55:09 +02:00
2021-09-11 21:23:49 +02:00
2019-11-15 12:25:46 +01:00
2020-07-02 19:55:09 +02:00
2019-11-14 23:30:37 +01:00
2019-11-15 12:25:45 +01:00
2021-09-11 21:23:49 +02:00
2020-07-02 19:55:09 +02:00
2020-07-03 00:03:44 +02:00
2020-07-02 19:55:10 +02:00
2021-09-11 21:23:48 +02:00
2020-07-02 19:55:09 +02:00
2020-07-02 19:55:09 +02:00
2019-11-15 12:25:45 +01:00
2021-09-11 21:23:48 +02:00
2019-11-14 23:30:37 +01:00
2021-09-11 21:23:48 +02:00
2020-07-03 00:03:45 +02:00
2019-11-15 12:25:47 +01:00
2019-11-15 12:25:46 +01:00
2019-11-15 12:25:45 +01:00
2019-11-15 12:25:45 +01:00
2019-11-15 12:25:45 +01:00