summaryrefslogtreecommitdiff
path: root/libavcodec/opus_silk.c
Commit message (Collapse)AuthorAge
* avcodec/opus_silk: Remove wrong size information in function declarationAndreas Rheinhardt2021-09-20
| | | | | | | | | | | | | | | | silk_lsp2poly()'s declaration contained arrays with array sizes; yet these array sizes exceeded the number of actually accessed array elements (which is related to another parameter) and this leads to -Wstringop-overflow= warnings from GCC 11, because the arrays provided by callers are only large enough for the actually used elements. So replace the incorrect array sizes with comments containing the correct array sizes. Given that these sizes are not compile-time constants, they can only be communicated via a comment. Reported by Paul B Mahol. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* opusdec: do not fail when LBRR frames are presentAnton Khirnov2020-10-01
| | | | | | Decode and discard them. Fixes ticket 4641.
* avcodec/opus_silk: Change silk_lsf2lpc() slightly toward silk/NLSF2A.cMichael Niedermayer2018-06-04
| | | | | | | | Fixes: runtime error: signed integer overflow: -1440457022 - 785819492 cannot be represented in type 'int' Fixes: 7700/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_OPUS_fuzzer-6595838684954624 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* opus_silk: Fix arithmetic overflow (per RFC8251)Andrew D'Addesio2017-12-04
| | | | | | | | | As per Sec.6 of RFC8251: Integer Wrap-Around in Inverse Gain Computation 32-bit integer overflow in Levinson recursion. Affects silk_is_lpc_stable(). Signed-off-by: Andrew D'Addesio <modchipv12@gmail.com>
* Merge commit 'fd9212f2edfe9b107c3c08ba2df5fd2cba5ab9e3'James Almer2017-09-26
|\ | | | | | | | | | | | | * commit 'fd9212f2edfe9b107c3c08ba2df5fd2cba5ab9e3': Mark some arrays that never change as const. Merged-by: James Almer <jamrial@gmail.com>
| * Mark some arrays that never change as const.Anton Khirnov2017-02-01
| |
* | avcodec/opus_silk: Fix integer overflow and out of array readMichael Niedermayer2017-05-06
| | | | | | | | | | | | | | Fixes: 1362/clusterfuzz-testcase-minimized-6097275002552320 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Merge commit '67deba8a416d818f3d95aef0aa916589090396e2'Clément Bœsch2017-03-31
|\| | | | | | | | | | | | | * commit '67deba8a416d818f3d95aef0aa916589090396e2': Use avpriv_report_missing_feature() where appropriate Merged-by: Clément Bœsch <cboesch@gopro.com>
| * Use avpriv_report_missing_feature() where appropriateDiego Biurrun2016-11-08
| |
* | opus: move the entropy decoding functions to opus_rc.cRostislav Pehlivanov2016-11-08
| | | | | | | | | | | | | | The intention is to have both encoding and decoding functions in opus_rc.c. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
* | opus: move all tables to a separate fileRostislav Pehlivanov2016-11-08
| | | | | | | | Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
* | Merge commit '5afb94c817abffad030c6b94d7003dca8aace3d5'Clément Bœsch2016-06-21
|\| | | | | | | | | | | | | * commit '5afb94c817abffad030c6b94d7003dca8aace3d5': Mark read-only tables as static Merged-by: Clément Bœsch <u@pkh.me>
| * Mark read-only tables as staticDiego Biurrun2016-05-05
| |
| * opus: Fix typo causing overflow in silk_stabilize_lsfAndreas Cadhalpun2015-12-16
| | | | | | | | | | | | | | | | | | | | Due to this typo max_center can be too large, causing nlsf to be set to too large values, which in turn can cause nlsf[i - 1] + min_delta[i] to overflow to a negative value, which is not allowed for nlsf and can cause an out of bounds read in silk_lsf2lpc. Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | opus_silk: fix typo causing overflow in silk_stabilize_lsfAndreas Cadhalpun2015-12-16
| | | | | | | | | | | | | | | | | | | | Due to this typo max_center can be too large, causing nlsf to be set to too large values, which in turn can cause nlsf[i - 1] + min_delta[i] to overflow to a negative value, which is not allowed for nlsf and can cause an out of bounds read in silk_lsf2lpc. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* | Merge commit '9abc80f1ed673141326341e26a05c3e1f78576d0'Michael Niedermayer2015-02-21
|\| | | | | | | | | | | | | | | | | | | * commit '9abc80f1ed673141326341e26a05c3e1f78576d0': libavcodec: Make use of av_clip functions Conflicts: libavcodec/takdec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * libavcodec: Make use of av_clip functionsPeter Meerwald2015-02-21
| | | | | | | | | | Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | Merge commit 'b70d7a4ac72d23f3448f3b08b770fdf5f57de222'Michael Niedermayer2014-05-15
|/ | | | | | | | | | | | | | | | | * commit 'b70d7a4ac72d23f3448f3b08b770fdf5f57de222': lavc: add a native Opus decoder. Conflicts: Changelog configure libavcodec/version.h Fate tests pass with both avresample as well as swresample based opus decoder, but are disabled (reference files are very large so i want to think a day or 2 about if theres an alternative or if they could be avoided, they also dont match the official samples) Merged-by: Michael Niedermayer <michaelni@gmx.at>
* lavc: add a native Opus decoder.Anton Khirnov2014-05-15
Initial implementation by Andrew D'Addesio <modchipv12@gmail.com> during GSoC 2012. Completion by Anton Khirnov <anton@khirnov.net>, sponsored by the Mozilla Corporation. Further contributions by: Christophe Gisquet <christophe.gisquet@gmail.com> Janne Grunau <janne-libav@jannau.net> Luca Barbato <lu_zero@gentoo.org>