File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
modules/juce_audio_devices/native Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -1115,14 +1115,17 @@ class CoreAudioInternal final : private Timer,
11151115 for (auto index = 0 ; index < numInputChans; ++index)
11161116 {
11171117 const auto info = inStream->channelInfo .getReference (index);
1118- const auto src = StrideIterator { ((const float *) inInputData->mBuffers [info.streamNum ].mData ) + info.dataOffsetSamples ,
1119- info.dataStrideSamples }
1120- + (ptrdiff_t ) sampleOffset;
1118+ auto src = StrideIterator { ((const float *) inInputData->mBuffers [info.streamNum ].mData ) + info.dataOffsetSamples ,
1119+ info.dataStrideSamples }
1120+ + (ptrdiff_t ) sampleOffset;
11211121
11221122 if (src.stride == 0 ) // if this is zero, info is invalid
11231123 continue ;
11241124
1125- std::copy (src, src + (ptrdiff_t ) numSamplesInChunk, inStream->tempBuffers [(size_t ) index]);
1125+ const auto end = src + (ptrdiff_t ) numSamplesInChunk;
1126+
1127+ for (auto dst = inStream->tempBuffers [(size_t ) index]; src != end; ++dst, ++src)
1128+ *dst = *src;
11261129 }
11271130
11281131 // only pass a timestamp for the first chunk of each buffer
You can’t perform that action at this time.
0 commit comments