From a376c91494c954491fd424f3b51ab4579b9846a2 Mon Sep 17 00:00:00 2001 From: Martin Sustrik Date: Thu, 16 Feb 2012 10:06:36 +0900 Subject: XS_CTX_MAX_SOCKETS option implemented To implement context options properly, initialisation of context is postponed till creation of the first socket. In the meantime it is possible to set socket options. Signed-off-by: Martin Sustrik --- include/xs.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/xs.h b/include/xs.h index 05d98ab..3aa1045 100644 --- a/include/xs.h +++ b/include/xs.h @@ -143,11 +143,15 @@ XS_EXPORT int xs_getmsgopt (xs_msg_t *msg, int option, void *optval, size_t *optvallen); /******************************************************************************/ -/* Crossroads infrastructure initialisation & termination. */ +/* Crossroads context definition. */ /******************************************************************************/ +#define XS_CTX_MAX_SOCKETS 1 + XS_EXPORT void *xs_init (int io_threads); XS_EXPORT int xs_term (void *context); +XS_EXPORT int xs_setctxopt (void *context, int option, const void *optval, + size_t optvallen); /******************************************************************************/ /* Crossroads socket definition. */ -- cgit v1.2.3