Solution: socket_base_t::in_event cannot do anything useful with
return status of process_commands. Asserting is the wrong solution,
as it is entirely valid to be interrupted or for the context to be
terminated, so discard the value.
Solution: remove statc initialization to NULL of thread.hpp pthread_t
descriptor. There is no portable way to statically initialize a
pthread_t variable.
Solution: The Coverity Static Code Analyzer was used on libzmq code and found
many issues with uninitialized member variables, some redefinition of variables
hidding previous instances of same variable name and a couple of functions
where return values were not checked, even though all other occurrences were
checked (e.g. init_size() return).
Solution: Corrected Toolset setting where needed and inprove compilation speed
by adding defintion of WIN32_LEAN_AND_MEAN prior to any Windows specific
include files, which skips non-essential definitions during compilation.
Solution: Corrected Toolset setting where needed and inprove compilation speed
by adding defintion of WIN32_LEAN_AND_MEAN prior to any Windows specific
include files, which skips non-essential definitions during compilation.
Solution: disable the warnings on this file only
We use pragmas wrapped in compiler conditionals. This will need
extending to non-gcc/msvc compilers. We could also fix the warnings
in the code, though I suspect it's not really possible.
Solution: Use CMD.EXE environment variable to extract DevStudio version
number and build using it. This even supports machines with multiple
DevStudio versions installed, as long as the build for each version is
done on a separate window with the correct environment.
If multiple version builds are desired from a single CMD.EXE, edit the
buildall.bat file to uncomment the build statements for each specific
version desired.
libzmq used to switch off pedantic checks when using tweetnacl. As
this is now the default, that means pedantic checks are always off.
This is not good.
Solution: in tweetnacl.c alone, use a GCC pragma to disable sign
comparison warnings. We could also clean the code up yet this is
simpler. In other code, we still want those warnings, hence I've
used a pragma rather than global compile option.
Second, use -Wno-long-long all the time, as this warning does not
work with a pragma.
I removed code that set -wno-long-long, for MinGW and Solaris.
Related problem 2: --with-relaxed is badly named
This option switches off pedantic checks, so should be called
--disable-pedantic. 'with' is for optional packages.
Gyp needs its own platform.hpp; there is no way to delete this
file automatically.
Solution: copy gyp's platform.hpp into src, so that things build
properly no matter what the starting state. If you build with gyp
and then try to build using autotools' makefile, you'll get an
error from the platform.hpp.
Solution: always initialised zmq::options_t class variables arrays to
avoid reading uninitialised data when CURVE is not yet configured and
a getsockopt ZMQ_CURVE_{SERVER | PUBLIC | SECRET]KEY is issued.