mirror of
https://codeberg.org/nahuhh/wownero
synced 2026-03-04 21:57:40 -05:00
zmq_server: fix bind call when address and/or port are empty
This commit is contained in:
committed by
wowario
parent
2c9c795f0c
commit
5cdbfe4e8b
@@ -104,6 +104,10 @@ bool ZmqServer::addTCPSocket(std::string address, std::string port)
|
||||
|
||||
rep_socket->setsockopt(ZMQ_RCVTIMEO, &DEFAULT_RPC_RECV_TIMEOUT_MS, sizeof(DEFAULT_RPC_RECV_TIMEOUT_MS));
|
||||
|
||||
if (address.empty())
|
||||
address = "*";
|
||||
if (port.empty())
|
||||
port = "*";
|
||||
std::string bind_address = addr_prefix + address + std::string(":") + port;
|
||||
rep_socket->bind(bind_address.c_str());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user