zeromq / zeromq4-x

ØMQ 4.x stable release branch - bug fixes only
GNU General Public License v3.0
458 stars 196 forks source link

Warning: Implicit conversion loses integer precision #140

Open neirar opened 8 years ago

neirar commented 8 years ago

Getting warnings in Xcode. In zmq.cpp, in the function zmq_poll(), the lines

return usleep (timeout_ * 1000);

and

timeout = end - now;

In zmp_utils.cpp, in the function zmq_z85_decode() the line

unsigned int string_len = strlen (string);

You need to either do a cast (in the case of usleep() since it is a system function and it expects and unsigned int), or you need to change the data type of the variables.

hintjens commented 8 years ago

For these and other issues on 4-x, please raise the issue on zeromq/libzmq, and if there is a fix already there, you can propose a backport of it to zeromq4-x (and make a pull request).

On Fri, Nov 13, 2015 at 12:53 PM, Roberto notifications@github.com wrote:

Getting warnings in Xcode. In zmq.cpp, in the function zmq_poll(), the lines

return usleep (timeout_ * 1000);

and

timeout = end - now;

In zmp_utils.cpp, in the function zmq_z85_decode() the line

unsigned int string_len = strlen (string);

You need to either do a cast (in the case of usleep() since it is a system function and it expects and unsigned int), or you need to change the data type of the variables.

— Reply to this email directly or view it on GitHub https://github.com/zeromq/zeromq4-x/issues/140.