mirror of
https://github.com/zeromq/libzmq.git
synced 2024-12-13 10:52:56 +01:00
Merge pull request #1202 from pavel-pimenov/fix-pvs-studio
PVS Studio small fix
This commit is contained in:
commit
3aa5a9d409
@ -494,7 +494,7 @@ void zmq::session_base_t::start_connecting (bool wait_)
|
||||
// Create the connecter object.
|
||||
|
||||
if (addr->protocol == "tcp") {
|
||||
if (options.socks_proxy_address != "") {
|
||||
if (!options.socks_proxy_address.empty()) {
|
||||
address_t *proxy_address = new (std::nothrow)
|
||||
address_t ("tcp", options.socks_proxy_address);
|
||||
alloc_assert (proxy_address);
|
||||
|
@ -96,7 +96,7 @@ zmq::stream_engine_t::stream_engine_t (fd_t fd_, const options_t &options_,
|
||||
|
||||
int family = get_peer_ip_address (s, peer_address);
|
||||
if (family == 0)
|
||||
peer_address = "";
|
||||
peer_address.clear();
|
||||
#if defined ZMQ_HAVE_SO_PEERCRED
|
||||
else
|
||||
if (family == PF_UNIX) {
|
||||
@ -781,7 +781,7 @@ void zmq::stream_engine_t::mechanism_ready ()
|
||||
it = zap_properties.begin ();
|
||||
while (it != zap_properties.end ()) {
|
||||
properties.insert (properties_t::value_type (it->first, it->second));
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
|
||||
// Add ZMTP properties.
|
||||
@ -789,7 +789,7 @@ void zmq::stream_engine_t::mechanism_ready ()
|
||||
it = zmtp_properties.begin ();
|
||||
while (it != zmtp_properties.end ()) {
|
||||
properties.insert (properties_t::value_type (it->first, it->second));
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
|
||||
zmq_assert (metadata == NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user