From: Antonio Larrosa Date: Mon, 6 Mar 2017 12:51:22 +0100 Subject: Always check the number of coefficients When building the library with NDEBUG, asserts are eliminated so it's better to always check that the number of coefficients is inside the array range. This fixes the 00191-audiofile-indexoob issue in #41 --- libaudiofile/WAVE.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libaudiofile/WAVE.cpp b/libaudiofile/WAVE.cpp index 9dd8511..0fc48e8 100644 --- a/libaudiofile/WAVE.cpp +++ b/libaudiofile/WAVE.cpp @@ -281,6 +281,12 @@ status WAVEFile::parseFormat(const Tag &id, uint32_t size) /* numCoefficients should be at least 7. */ assert(numCoefficients >= 7 && numCoefficients <= 255); + if (numCoefficients < 7 || numCoefficients > 255) + { + _af_error(AF_BAD_HEADER, + "Bad number of coefficients"); + return AF_FAIL; + } m_msadpcmNumCoefficients = numCoefficients; sub right'>
aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/tree-sitter.scm
AgeCommit message (Expand)Author
2023-10-08gnu: Add tree-sitter-scala....* gnu/packages/tree-sitter.scm (tree-sitter-scala): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Karl Hallsby
2023-10-08gnu: Add tree-sitter-lua....* gnu/packages/tree-sitter.scm (tree-sitter-lua): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> john muhl
2023-10-05gnu: tree-sitter-java: Update to 0.20.1....* gnu/packages/tree-sitter.scm (tree-sitter-java): Update to 0.20.1. Signed-off-by: Andrew Tropin <andrew@trop.in> Kjartan Oli Agustsson
2023-09-01gnu: Add tree-sitter-plantuml....* gnu/packages/tree-sitter.scm (tree-sitter-plantuml): New variable. Andrew Tropin
2023-09-01gnu: tree-sitter-grammar: Add get-cleanup-snippet argument....* gnu/packages/tree-sitter.scm (tree-sitter-grammar): Add get-cleanup-snippet argument. Andrew Tropin
2023-08-27gnu: Add tree-sitter-cmake....* gnu/packages/tree-sitter.scm (tree-sitter-cmake): New variable. Hilton Chain
2023-08-20gnu: Add tree-sitter-meson....* gnu/packages/tree-sitter.scm (tree-sitter-meson): New variable. Signed-off-by: Hilton Chain <hako@ultrarare.space> Zheng Junjie
2023-08-20gnu: Add tree-sitter-dockerfile....* gnu/packages/tree-sitter.scm (tree-sitter-dockerfile): New variable. Hilton Chain
2023-07-18gnu: tree-sitter-json: Update to 0.20.0....* gnu/packages/tree-sitter.scm (tree-sitter-json): Update to 0.20.0. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Hilton Chain
2023-07-09gnu: Add tree-sitter-gomod....* gnu/packages/tree-sitter.scm (tree-sitter-gomod): New variable. Danny Milosavljevic
2023-07-01gnu: Add python-tree-sitter....* gnu/packages/tree-sitter.scm (python-tree-sitter): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Reviewed-by: Jean-Pierre De Jesus DIAZ <jean@foundationdevices.com> Nicolas Graves
2023-06-13gnu: Add tree-sitter-bibtex....* gnu/packages/tree-sitter.scm (tree-sitter-bibtex): New variable. Nicolas Graves via Guix-patches via