From f482ba8f7b53c566d13932cb4ee3f6736ac8938e Mon Sep 17 00:00:00 2001 From: atraczyk <andreastraczyk@gmail.com> Date: Tue, 13 Dec 2016 12:33:31 -0500 Subject: [PATCH] audio: remove C99 compound literals - Microsoft's compiler doesn't support C99 compound literals. This patch replaces these expressions with C++11 unnamed temporary list initializations. Change-Id: I23d1aa5beb2ae0b7ae73ff02b5a5897ee83b2979 Tuleap: #790 --- src/media/audio/dcblocker.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/media/audio/dcblocker.cpp b/src/media/audio/dcblocker.cpp index 9d2c4b3662..c38d9c411e 100644 --- a/src/media/audio/dcblocker.cpp +++ b/src/media/audio/dcblocker.cpp @@ -25,12 +25,12 @@ namespace ring { DcBlocker::DcBlocker(unsigned channels /* = 1 */) - : states(channels, (struct StreamState){0, 0, 0, 0}) + : states(channels, StreamState{0, 0, 0, 0}) {} void DcBlocker::reset() { - states.assign(states.size(), (struct StreamState){0, 0, 0, 0}); + states.assign(states.size(), StreamState{0, 0, 0, 0}); } void DcBlocker::doProcess(AudioSample *out, AudioSample *in, unsigned samples, struct StreamState * state) @@ -58,7 +58,7 @@ void DcBlocker::process(AudioBuffer& buf) const size_t chans = buf.channels(); const size_t samples = buf.frames(); if (chans > states.size()) - states.resize(buf.channels(), (struct StreamState){0, 0, 0, 0}); + states.resize(buf.channels(), StreamState{0, 0, 0, 0}); unsigned i; for(i=0; i<chans; i++) { -- GitLab