diff --git a/common/JackAudioAdapterInterface.cpp b/common/JackAudioAdapterInterface.cpp index c75b9297..ee90edd4 100644 --- a/common/JackAudioAdapterInterface.cpp +++ b/common/JackAudioAdapterInterface.cpp @@ -293,8 +293,9 @@ namespace Jack int JackAudioAdapterInterface::PullAndPush(float** inputBuffer, float** outputBuffer, unsigned int frames) { fPullAndPushTime = GetMicroSeconds(); - if (!fRunning) + if (!fRunning) { return 0; + } int res = 0; diff --git a/common/JackNetAPI.cpp b/common/JackNetAPI.cpp index 553edf2b..443240bd 100644 --- a/common/JackNetAPI.cpp +++ b/common/JackNetAPI.cpp @@ -418,7 +418,7 @@ struct JackNetExtMaster : public JackNetMasterInterface { int res = SyncRecv(); switch (res) { - case 0: + case NET_SYNCHING: case SOCKET_ERROR: return res; diff --git a/common/JackNetInterface.cpp b/common/JackNetInterface.cpp index f4c49c47..901da5f9 100644 --- a/common/JackNetInterface.cpp +++ b/common/JackNetInterface.cpp @@ -494,7 +494,7 @@ namespace Jack if (fCurrentCycleOffset < fMaxCycleOffset && !fSynched) { jack_info("Synching with latency = %d", fCurrentCycleOffset); - return 0; + return NET_SYNCHING; } else { if (fCurrentCycleOffset == fMaxCycleOffset) { // when the sync offset is reached diff --git a/common/JackNetManager.cpp b/common/JackNetManager.cpp index 7f96d2cc..38a444a5 100644 --- a/common/JackNetManager.cpp +++ b/common/JackNetManager.cpp @@ -520,7 +520,7 @@ namespace Jack int res = SyncRecv(); switch (res) { - case 0: + case NET_SYNCHING: case SOCKET_ERROR: return res; diff --git a/common/JackNetTool.h b/common/JackNetTool.h index d8d47d22..8e5e2bc1 100644 --- a/common/JackNetTool.h +++ b/common/JackNetTool.h @@ -41,6 +41,7 @@ using namespace std; #define MASTER_PROTOCOL 6 #define SLAVE_PROTOCOL 6 +#define NET_SYNCHING 0 #define NET_PACKET_ERROR -2 #define OPTIMIZED_PROTOCOL 1