diff data/model/WritableWaveFileModel.cpp @ 225:185454896a76

* Return ranges from RangeSummarisableTimeValueModel::getRanges by references instead of by return value. Trying to isolate a Win32 problem.
author Chris Cannam
date Wed, 07 Feb 2007 14:21:14 +0000
parents 91fdc752e540
children 96a6dd889c68
line wrap: on
line diff
--- a/data/model/WritableWaveFileModel.cpp	Thu Feb 01 14:31:28 2007 +0000
+++ b/data/model/WritableWaveFileModel.cpp	Wed Feb 07 14:21:14 2007 +0000
@@ -167,12 +167,14 @@
     return m_model->getValues(channel, start, end, buffer);
 }
 
-WritableWaveFileModel::RangeBlock
+void
 WritableWaveFileModel::getRanges(size_t channel, size_t start, size_t end,
+                                 RangeBlock &ranges,
                                  size_t &blockSize) const
 {
-    if (!m_model || m_model->getChannelCount() == 0) return RangeBlock();
-    return m_model->getRanges(channel, start, end, blockSize);
+    ranges.clear();
+    if (!m_model || m_model->getChannelCount() == 0) return;
+    m_model->getRanges(channel, start, end, ranges, blockSize);
 }
 
 WritableWaveFileModel::Range