mirror of
https://github.com/zeromq/libzmq.git
synced 2025-02-22 07:01:14 +01:00
Fixed zmq_init(-1) issue
This commit is contained in:
parent
cecc790ca3
commit
eb8217bb28
10
src/zmq.cpp
10
src/zmq.cpp
@ -210,9 +210,13 @@ int zmq_ctx_get (void *ctx_, int option_)
|
|||||||
|
|
||||||
void *zmq_init (int io_threads_)
|
void *zmq_init (int io_threads_)
|
||||||
{
|
{
|
||||||
void *ctx = zmq_ctx_new ();
|
if (io_threads_ >= 0) {
|
||||||
zmq_ctx_set (ctx, ZMQ_IO_THREADS, io_threads_);
|
void *ctx = zmq_ctx_new ();
|
||||||
return ctx;
|
zmq_ctx_set (ctx, ZMQ_IO_THREADS, io_threads_);
|
||||||
|
return ctx;
|
||||||
|
}
|
||||||
|
errno = EINVAL;
|
||||||
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
int zmq_term (void *ctx_)
|
int zmq_term (void *ctx_)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user