Commit 600877ee authored by sletz's avatar sletz
Browse files

JackAudioDriver::ProcessAsync and JackAudioDriver::ProcessSync were broken at...

JackAudioDriver::ProcessAsync and JackAudioDriver::ProcessSync were broken at some point : 0 has to be returned in all cases.

git-svn-id: http://subversion.jackaudio.org/jack/jack2/trunk/jackmp@2288 0c269be4-1314-0410-8aa9-9f06e86f4224
parent beb4cfc0
......@@ -24,6 +24,7 @@ Fernando Lopez-Lezcano
* Use of placement new for dynamic port allocation is possibly not safe... so avoid that until a definitive answer is found.
* Cleanup.
* JackAudioDriver::ProcessAsync and JackAudioDriver::ProcessSync were broken at some point : 0 has to be returned in all cases.
2008-05-16 Stephane Letz <letz@grame.fr>
......
......@@ -186,14 +186,16 @@ synchronize to the end of client graph execution.
int JackAudioDriver::ProcessAsync()
{
if (Read() < 0) { // Read input buffers for the current cycle
// Read input buffers for the current cycle
if (Read() < 0) {
jack_error("ProcessAsync: read error, skip cycle");
return -1;
return 0; // Skip cycle, but continue processing...
}
if (Write() < 0) { // Write output buffers from the previous cycle
// Write output buffers from the previous cycle
if (Write() < 0) {
jack_error("ProcessAsync: write error, skip cycle");
return -1;
return 0; // Skip cycle, but continue processing...
}
if (fIsMaster) {
......@@ -215,9 +217,10 @@ output buffers computed at the *current cycle* are used.
int JackAudioDriver::ProcessSync()
{
if (Read() < 0) { // Read input buffers for the current cycle
// Read input buffers for the current cycle
if (Read() < 0) {
jack_error("ProcessSync: read error, skip cycle");
return -1;
return 0; // Skip cycle, but continue processing...
}
if (fIsMaster) {
......@@ -232,9 +235,10 @@ int JackAudioDriver::ProcessSync()
jack_error("ProcessSync: error");
}
if (Write() < 0) { // Write output buffers for the current cycle
// Write output buffers for the current cycle
if (Write() < 0) {
jack_error("ProcessSync: write error, skip cycle");
return -1;
return 0; // Skip cycle, but continue processing...
}
} else {
......
......@@ -427,7 +427,7 @@ int JackDebugClient::SetProcessCallback(JackProcessCallback callback, void *arg)
CheckClient();
fProcessTimeCallback = callback;
fProcessTimeCallbackArg = arg;
return fClient->SetProcessCallback(TimeCallback, this);
return fClient->SetProcessCallback(TimeCallback, this);
}
int JackDebugClient::SetXRunCallback(JackXRunCallback callback, void *arg)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment