diff options
Diffstat (limited to 'src/pcm/PcmDsd.cxx')
-rw-r--r-- | src/pcm/PcmDsd.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/pcm/PcmDsd.cxx b/src/pcm/PcmDsd.cxx index b74d812e2..6df6511e5 100644 --- a/src/pcm/PcmDsd.cxx +++ b/src/pcm/PcmDsd.cxx @@ -55,9 +55,7 @@ PcmDsd::ToFloat(unsigned channels, ConstBuffer<uint8_t> src) const unsigned num_samples = src.size; const unsigned num_frames = src.size / channels; - float *dest; - const size_t dest_size = num_samples * sizeof(*dest); - dest = (float *)buffer.Get(dest_size); + float *dest = buffer.GetT<float>(num_samples); for (unsigned c = 0; c < channels; ++c) { if (dsd2pcm[c] == nullptr) { |