Of course people still "can" distributed the sources under the
LGPLv3. However we provide COPYING.LESSER with additional grants.
Solution: specify these grants in the header of each source file.
This is a silly assertion that causes problems if libzmq.dll is
called in some esoteric ways.
Solution: if the shutdown code detects WSANOTINITIALISED, then
exit silently.
Fixes#1377Fixes#1144
Updated:
src/signaler.cpp: Add close_wait_ms() static function to loop
when receiving EAGAIN in response to close(), with ms long
sleeps, up to a maximum limit (default 2000ms == 2 seconds);
used in signaler_t::~signaler_t() destructor.
The decision about the poller mechanism to use (select, poll, ...)
was done twice: once by the build system and once by the code in
poller.hpp. As the build-system can actually detect the mechanisms
available, prefer that result to the hard coded defaults in
poller.hpp.
At the same time, remove the duplicate detection of select() vs.
poll()-variant from proxy.cpp, signaler.cpp and zmq.cpp.
This patch has not been tested on many build platforms: especially
the cmake build needs testing / patching. For the other builds,
hard code the result as these these are all Windows platforms.
Copyrights had become ads for Sustrik's corporate sponsors, going against the original
agreement to share copyrights with the community (that agreement was: one line stating
iMatix copyright + one reference to AUTHORS file). The proliferation of corporate ads
is also unfair to the many individual authors. I've removed ALL corporate title from
the source files so the copyright statements can now be centralized in AUTHORS and
source files can be properly updated on an annual basis.
- Windows CE does not manage security attributes (no SetSecurityDescriptorDacl(), SetEvent (NULL, xxx) ...)
- Windows CE does not inheritance of sockets for child process (SetHandleInformation ((HANDLE) *w_, HANDLE_FLAG_INHERIT...)
- see comments about story "Porting ZeroMQ to Windows Mobile" on webpage http://www.zeromq.org/story:5
By assigning a SECURITY_DESCRIPTOR to the event we gain the ability to
share it between service and console programs. We also added
EVENT_MODIFY_STATE as a requirement to OpenEvent so we can SetEvent later
in the method.
The CreateEvent function requests EVENT_ALL_ACCESS access rights
when the event object already exists. This causes problems
when the event object is created from a service.
The solution is to call OpenEvent function when the CreateEvent
failed due to access control.
The proper solution would be to use CreateEventEx function, but
this one is not available on Windows XP.
* Added two new files: errno.hpp and errno.cpp. They are required to use errno functionality on WM.
* zmq.cpp, msg.h: removed inclusion of errno.h because it is included in zmq.h that is also included by .cpp.
* windows.hpp: process.h is included only for desktop builds.
* thread.cpp: on CE CreateThread is used instead of __beginthreadex
* socket_base.cpp, clock.cpp: on CE include cmnintrin.h instead on intrin.h
* signaler.cpp: on Windows should use special macro around event name (for unicode builds)
* err.hpp: make it include errno.hpp (my file) instead on errno.h when building for CE
* err.cpp: use FormatMessage when building for CE (because CE does not have ANSI API functions)
* zmq.h: do not include errno.h whe building for CE
* libzmq.vcproj: add tro new files