Skip to content

Commit

Permalink
In FlexASIOTest, ensure callbacks are finished before incrementing.
Browse files Browse the repository at this point in the history
See #7.
  • Loading branch information
dechamps committed Oct 24, 2018
1 parent 085cffb commit 028e71b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions FlexASIOTest/test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -421,8 +421,8 @@ namespace flexasio_test {
callbacks.bufferSwitch = [&](long doubleBufferIndex, ASIOBool directProcess) {
std::cout << "bufferSwitch(doubleBufferIndex = " << doubleBufferIndex << ", directProcess = " << directProcess << ")" << std::endl;
GetSamplePosition();
incrementBufferSwitchCount();
std::cout << "<-" << std::endl;
incrementBufferSwitchCount();
};
callbacks.sampleRateDidChange = [&](ASIOSampleRate sampleRate) {
std::cout << "sampleRateDidChange(" << sampleRate << ")" << std::endl;
Expand All @@ -438,8 +438,8 @@ namespace flexasio_test {
std::cout << "bufferSwitchTimeInfo(params = " << params << ", doubleBufferIndex = " << doubleBufferIndex << ", directProcess = " << directProcess << ")" << std::endl;
if (params != nullptr) PrintASIOTime(*params);
GetSamplePosition();
incrementBufferSwitchCount();
std::cout << "<- nullptr" << std::endl;
incrementBufferSwitchCount();
return nullptr;
};

Expand Down

0 comments on commit 028e71b

Please sign in to comment.