diff --git a/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp b/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp index 64170bb3a4..57e2a18325 100644 --- a/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp +++ b/modules/juce_audio_formats/codecs/juce_WavAudioFormat.cpp @@ -85,7 +85,7 @@ namespace WavFileHelpers uint8 reserved[190]; char codingHistory[1]; - void copyTo (StringPairArray& values) const + void copyTo (StringPairArray& values, const int totalSize) const { values.set (WavAudioFormat::bwavDescription, String::fromUTF8 (description, 256)); values.set (WavAudioFormat::bwavOriginator, String::fromUTF8 (originator, 32)); @@ -98,7 +98,8 @@ namespace WavFileHelpers const int64 time = (((int64)timeHigh) << 32) + timeLow; values.set (WavAudioFormat::bwavTimeReference, String (time)); - values.set (WavAudioFormat::bwavCodingHistory, String::fromUTF8 (codingHistory)); + values.set (WavAudioFormat::bwavCodingHistory, + String::fromUTF8 (codingHistory, totalSize - offsetof (BWAVChunk, codingHistory))); } static MemoryBlock createFrom (const StringPairArray& values) @@ -591,7 +592,7 @@ public: HeapBlock bwav; bwav.calloc (jmax ((size_t) length + 1, sizeof (BWAVChunk)), 1); input->read (bwav, (int) length); - bwav->copyTo (metadataValues); + bwav->copyTo (metadataValues, (int) length); } else if (chunkType == chunkName ("smpl")) { diff --git a/modules/juce_audio_plugin_client/RTAS/juce_RTAS_Wrapper.cpp b/modules/juce_audio_plugin_client/RTAS/juce_RTAS_Wrapper.cpp index 632d68d533..8ead501720 100644 --- a/modules/juce_audio_plugin_client/RTAS/juce_RTAS_Wrapper.cpp +++ b/modules/juce_audio_plugin_client/RTAS/juce_RTAS_Wrapper.cpp @@ -977,7 +977,12 @@ private: case 5: return ePlugIn_StemFormat_5dot0; case 6: return ePlugIn_StemFormat_5dot1; case 7: return ePlugIn_StemFormat_6dot1; + + #if PT_VERS_MAJOR >= 9 + case 8: return ePlugIn_StemFormat_7dot1DTS + #else case 8: return ePlugIn_StemFormat_7dot1; + #endif default: jassertfalse; break; // hmm - not a valid number of chans for RTAS.. }