summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2017-01-10 16:48:48 +0000
committerCarl Hetherington <cth@carlh.net>2017-01-10 16:48:48 +0000
commit3ce6111d48e766840ac85018454115d6b0f95583 (patch)
tree73674a503af7568fb8ec7f69ed9824fc1d26805b /src
parentcd227240e321a31e819bda37f22285c2dbe813ae (diff)
Fix valgrind warning.
Diffstat (limited to 'src')
-rw-r--r--src/sound_asset_writer.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sound_asset_writer.cc b/src/sound_asset_writer.cc
index e084d0d5..74bf866e 100644
--- a/src/sound_asset_writer.cc
+++ b/src/sound_asset_writer.cc
@@ -75,6 +75,11 @@ SoundAssetWriter::SoundAssetWriter (SoundAsset* asset, boost::filesystem::path f
_state->desc.ChannelFormat = ASDCP::PCM::CF_CFG_4;
}
+ /* I'm fairly sure this is not necessary, as ContainerDuration is written
+ in ASDCP's WriteMXFFooter, but it stops a valgrind warning.
+ */
+ _state->desc.ContainerDuration = 0;
+
_state->frame_buffer.Capacity (ASDCP::PCM::CalcFrameBufferSize (_state->desc));
_state->frame_buffer.Size (ASDCP::PCM::CalcFrameBufferSize (_state->desc));
memset (_state->frame_buffer.Data(), 0, _state->frame_buffer.Capacity());