FIX: fixed the tcp client
This commit is contained in:
@@ -41,7 +41,9 @@ namespace DirectCommunication
|
||||
|
||||
zmq::message_t zmqMsg(msg.begin(),msg.end());
|
||||
|
||||
socket_.send(zmqMsg,zmq::send_flags::dontwait);
|
||||
if (isConnected == true) {
|
||||
socket_.send(zmqMsg,zmq::send_flags::dontwait);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -70,7 +72,7 @@ namespace DirectCommunication
|
||||
|
||||
if (msg.to_string() == "CLOSE")
|
||||
{
|
||||
|
||||
isConnected = false;
|
||||
socket_.disconnect("tcp://"+serverAddress_+":"+std::to_string(port_));
|
||||
|
||||
}else
|
||||
|
||||
Reference in New Issue
Block a user