From 99b63cf0384a23312fe2d7ba024f4edcea3b301c Mon Sep 17 00:00:00 2001 From: attila Date: Wed, 2 Apr 2025 11:26:17 +0200 Subject: [PATCH] WavAudioFormat: Fix reading odd-sized INFO chunks in a LIST block --- modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp b/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp index 77e47f79f9..10636d8dfb 100644 --- a/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp +++ b/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp @@ -800,6 +800,10 @@ namespace WavFileHelpers { MemoryBlock mb; input.readIntoMemoryBlock (mb, (ssize_t) infoLength); + + if (infoLength & 1) + input.skipNextBytes (1); + values[type] = String::createStringFromData ((const char*) mb.getData(), (int) mb.getSize()); break;