Destructing singleton context (or global variable context) in a DLL produces WSASTARTUP error

Description

Create a singleton holding a context or a global variable zmq::context_t (c++ bindings but problem is with zmq_term function). Ship this singleton / global in a DLL. Link to an exe program and it will fail when calling destructor (zmq_term).

However, if the context is self-contained inside some object which is not global, then it is destroyed properly.

Context is initialized only once, application is single-threaded.

I don't know if it is reproducible under linux / other environments. It fails on Windows 7 x64 with ZeroMQ-4.0.1, used gtest.

Environment

Windows 7 x64, VS2010. Single-threaded application

Activity

Show:

Details

Assignee

Reporter

Labels

Components

Affects versions

Priority

Created November 6, 2013 at 10:42 AM
Updated November 6, 2013 at 10:42 AM