[zeromq-dev] interrupt handling Ctrl-C

pprun pprun.dragon at gmail.com
Thu Nov 22 12:49:00 CET 2012


Well, seems it was renamed(zctx_interrupted):
//  Global signal indicator, TRUE when user presses Ctrl-C or the process
//  gets a SIGTERM signal.
CZMQ_EXPORT extern volatile int zctx_interrupted;

Thank you for the comment.

Pprun


On 11/22/2012 06:28 PM, Pieter Hintjens wrote:
> This function is replaced by the handling czmq does automatically, when
> you call zctx_new.
>
> On Nov 22, 2012 5:45 PM, "pprun" <pprun.dragon at gmail.com
> <mailto:pprun.dragon at gmail.com>> wrote:
>
>     Hi,
>     In zguide, there's description for interrupt handling,
>     and the comment for the help function is:
>
>     // Call s_catch_signals() in your application at startup, and then exit
>     // your main loop if s_interrupted is ever 1. Works especially well with
>     // zmq_poll.
>
>     I want to know should this function be called ONLY on main thread? Or,
>     it should be set on every threads, spawned by zthread_new from main
>     thread?
>
>     thanks,
>     Pprun
>
>     _______________________________________________
>     zeromq-dev mailing list
>     zeromq-dev at lists.zeromq.org <mailto:zeromq-dev at lists.zeromq.org>
>     http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>
>
>
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev



More information about the zeromq-dev mailing list