mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-05 20:57:40 +01:00
Problem: C4267 warnings due to implicit conversion from size_t to int
Solution: change variable type to size_t
This commit is contained in:
@@ -124,7 +124,7 @@ static std::string make_address_string (const char *hbuf,
|
||||
char *pos = buf;
|
||||
memcpy (pos, ipv6_prefix, sizeof ipv6_prefix - 1);
|
||||
pos += sizeof ipv6_prefix - 1;
|
||||
const int hbuf_len = strlen (hbuf);
|
||||
const size_t hbuf_len = strlen (hbuf);
|
||||
memcpy (pos, hbuf, hbuf_len);
|
||||
pos += hbuf_len;
|
||||
memcpy (pos, ipv6_suffix, sizeof ipv6_suffix - 1);
|
||||
@@ -296,7 +296,7 @@ int zmq::tcp_address_mask_t::to_string (std::string &addr_) const
|
||||
memcpy (pos, ipv6_prefix, sizeof ipv6_prefix - 1);
|
||||
pos += sizeof ipv6_prefix - 1;
|
||||
}
|
||||
const int hbuf_len = strlen (hbuf);
|
||||
const size_t hbuf_len = strlen (hbuf);
|
||||
memcpy (pos, hbuf, hbuf_len);
|
||||
pos += hbuf_len;
|
||||
if (_network_address.family () == AF_INET6) {
|
||||
|
||||
Reference in New Issue
Block a user