diff --git a/common/JackDebugClient.cpp b/common/JackDebugClient.cpp index e5efa7da..27e07dc5 100644 --- a/common/JackDebugClient.cpp +++ b/common/JackDebugClient.cpp @@ -417,7 +417,7 @@ jack_nframes_t JackDebugClient::GetCurrentTransportFrame() return fClient->GetCurrentTransportFrame(); } -int JackDebugClient::TransportReposition(jack_position_t* pos) +int JackDebugClient::TransportReposition(const jack_position_t* pos) { CheckClient("TransportReposition"); return fClient->TransportReposition(pos); diff --git a/common/JackDebugClient.h b/common/JackDebugClient.h index 7256552e..fa50fc31 100644 --- a/common/JackDebugClient.h +++ b/common/JackDebugClient.h @@ -106,7 +106,7 @@ class JackDebugClient : public JackClient void TransportLocate(jack_nframes_t frame); jack_transport_state_t TransportQuery(jack_position_t* pos); jack_nframes_t GetCurrentTransportFrame(); - int TransportReposition(jack_position_t* pos); + int TransportReposition(const jack_position_t* pos); void TransportStart(); void TransportStop(); diff --git a/common/JackGenericClientChannel.h b/common/JackGenericClientChannel.h index e866feeb..fb125915 100644 --- a/common/JackGenericClientChannel.h +++ b/common/JackGenericClientChannel.h @@ -57,8 +57,6 @@ class JackGenericClientChannel : public detail::JackClientChannelInterface void ClientCheck(const char* name, int uuid, char* name_res, int protocol, int options, int* status, int* result, int open); void ClientOpen(const char* name, int pid, int uuid, int* shared_engine, int* shared_client, int* shared_graph, int* result); - void ClientOpen(const char* name, int* ref, int uuid, JackEngineControl** shared_engine, JackGraphManager** shared_manager, JackClientInterface* client, int* result) - {} void ClientClose(int refnum, int* result); void ClientActivate(int refnum, int is_real_time, int* result); diff --git a/common/JackNetDriver.cpp b/common/JackNetDriver.cpp index 12019ba0..02b20335 100644 --- a/common/JackNetDriver.cpp +++ b/common/JackNetDriver.cpp @@ -286,7 +286,7 @@ namespace Jack //port latency port = fGraphManager->GetPort(port_index); port->SetAlias(alias); - range.min = range.max = (fParams.fNetworkLatency * fEngineControl->fBufferSize + (fEngineControl->fSyncMode) ? 0 : fEngineControl->fBufferSize); + range.min = range.max = (fParams.fNetworkLatency * fEngineControl->fBufferSize + ((fEngineControl->fSyncMode) ? 0 : fEngineControl->fBufferSize)); port->SetLatencyRange(JackPlaybackLatency, &range); fPlaybackPortList[audio_port_index] = port_index; jack_log("JackNetDriver::AllocPorts() fPlaybackPortList[%d] audio_port_index = %ld fPortLatency = %ld", audio_port_index, port_index, port->GetLatency()); @@ -321,7 +321,7 @@ namespace Jack //port latency port = fGraphManager->GetPort(port_index); - range.min = range.max = (fParams.fNetworkLatency * fEngineControl->fBufferSize + (fEngineControl->fSyncMode) ? 0 : fEngineControl->fBufferSize); + range.min = range.max = (fParams.fNetworkLatency * fEngineControl->fBufferSize + ((fEngineControl->fSyncMode) ? 0 : fEngineControl->fBufferSize)); port->SetLatencyRange(JackPlaybackLatency, &range); fMidiPlaybackPortList[midi_port_index] = port_index; jack_log("JackNetDriver::AllocPorts() fMidiPlaybackPortList[%d] midi_port_index = %ld fPortLatency = %ld", midi_port_index, port_index, port->GetLatency()); diff --git a/common/JackNetInterface.cpp b/common/JackNetInterface.cpp index 6a045507..3ad42b1a 100644 --- a/common/JackNetInterface.cpp +++ b/common/JackNetInterface.cpp @@ -632,7 +632,7 @@ namespace Jack bool JackNetSlaveInterface::InitConnection(int time_out_sec) { jack_log("JackNetSlaveInterface::InitConnection()"); - uint try_count = (time_out_sec > 0) ? ((1000000 * time_out_sec) / SLAVE_INIT_TIMEOUT) : LONG_MAX; + uint try_count = (time_out_sec > 0) ? ((1000000 * time_out_sec) / SLAVE_INIT_TIMEOUT) : UINT_MAX; // set the parameters to send strcpy(fParams.fPacketType, "params"); diff --git a/common/JackNetTool.h b/common/JackNetTool.h index c622acee..5d4559a1 100644 --- a/common/JackNetTool.h +++ b/common/JackNetTool.h @@ -324,9 +324,6 @@ namespace Jack virtual int RenderFromNetwork(int cycle, int sub_cycle, uint32_t port_num) = 0; virtual int RenderToNetwork(int sub_cycle, uint32_t port_num) = 0; - virtual void RenderFromNetwork(char* net_buffer, int active_port, int sub_cycle, size_t copy_size) {} - virtual void RenderToNetwork(char* net_buffer, int active_port, int sub_cycle, size_t copy_size) {} - virtual int ActivePortsToNetwork(char* net_buffer); virtual void ActivePortsFromNetwork(char* net_buffer, uint32_t port_num); @@ -340,6 +337,10 @@ namespace Jack int fPacketSize; void UpdateParams(int active_ports); + + + void RenderFromNetwork(char* net_buffer, int active_port, int sub_cycle); + void RenderToNetwork(char* net_buffer, int active_port, int sub_cycle); public: @@ -357,9 +358,6 @@ namespace Jack int RenderFromNetwork(int cycle, int sub_cycle, uint32_t port_num); int RenderToNetwork(int sub_cycle, uint32_t port_num); - void RenderFromNetwork(char* net_buffer, int active_port, int sub_cycle); - void RenderToNetwork(char* net_buffer, int active_port, int sub_cycle); - }; #if HAVE_CELT diff --git a/posix/JackPosixSemaphore.cpp b/posix/JackPosixSemaphore.cpp index bede0f41..f915ef70 100644 --- a/posix/JackPosixSemaphore.cpp +++ b/posix/JackPosixSemaphore.cpp @@ -94,8 +94,9 @@ bool JackPosixSemaphore::Wait() while ((res = sem_wait(fSemaphore) < 0)) { jack_error("JackPosixSemaphore::Wait name = %s err = %s", fName, strerror(errno)); - if (errno != EINTR) + if (errno != EINTR) { break; + } } return (res == 0); } @@ -122,8 +123,9 @@ bool JackPosixSemaphore::TimedWait(long usec) jack_error("JackPosixSemaphore::TimedWait err = %s", strerror(errno)); jack_log("JackPosixSemaphore::TimedWait now : %ld %ld ", now.tv_sec, now.tv_usec); jack_log("JackPosixSemaphore::TimedWait next : %ld %ld ", time.tv_sec, time.tv_nsec/1000); - if (errno != EINTR) + if (errno != EINTR) { break; + } } return (res == 0); }