summaryrefslogtreecommitdiff
path: root/src/pcm
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2020-01-14 22:39:54 +0100
committerMax Kellermann <max@musicpd.org>2020-01-14 22:39:54 +0100
commita65f7b1006d445e6deb2882afa97488d7ff108bc (patch)
tree582412730f3a1f1e9fafca855af3f63dc8f7ae2e /src/pcm
parentbc5b647053d460318af21a9357974a8816dcdc94 (diff)
pcm/Dsd2Pcm: use std::fill_n()
Diffstat (limited to 'src/pcm')
-rw-r--r--src/pcm/Dsd2Pcm.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/pcm/Dsd2Pcm.cxx b/src/pcm/Dsd2Pcm.cxx
index 37421804b..aafb524a2 100644
--- a/src/pcm/Dsd2Pcm.cxx
+++ b/src/pcm/Dsd2Pcm.cxx
@@ -151,8 +151,9 @@ static constexpr auto ctables = GenerateArray<CTABLES>(GenerateCtable);
void
Dsd2Pcm::Reset() noexcept
{
- for (int i = 0; i < FIFOSIZE; ++i)
- fifo[i] = 0x69; /* my favorite silence pattern */
+ /* my favorite silence pattern */
+ std::fill_n(fifo, std::size(fifo), 0x69);
+
fifopos = 0;
/* 0x69 = 01101001
* This pattern "on repeat" makes a low energy 352.8 kHz tone