zeromq / rbzmq

Ruby binding for 0MQ

Home Page:http://www.zeromq.org/bindings:ruby

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ZMQ hangs on exit.

kybu opened this issue · comments

commented

Caute borci,

I have a following issue on Debian stable using libzmq 2.1.10-1 compiled from unstable, so I am not sure if it goes on account of Ruby bindings or zmq library itself. ruby-1.9.2-p290 hangs when running an example from README.rdoc. Here is a stack of all threads.

(gdb) bt
#0  0xb78b8424 in __kernel_vsyscall ()
#1  0xb75a9696 in poll () from /lib/i686/cmov/libc.so.6
#2  0xb72bbc7b in zmq::signaler_t::wait (this=0x8c53338, timeout_=-1) at signaler.cpp:145
#3  0xb72ac75b in zmq::mailbox_t::recv (this=0x8c53308, cmd_=0xbfa0ab78, timeout_=-1) at mailbox.cpp:69
#4  0xb72a5322 in zmq::ctx_t::terminate (this=0x8c532b8) at ctx.cpp:146
#5  0xb72c7808 in zmq_term (ctx_=0x8c532b8) at zmq.cpp:292
#6  0xb76c15e1 in context_free (ctx=0xfffffdfc) at rbzmq.c:98
#7  0xb7733b9a in run_final (objspace=0x8aa6440) at gc.c:2605
#8  finalize_list (objspace=0x8aa6440) at gc.c:1808
#9  rb_objspace_call_finalizer (objspace=0x8aa6440) at gc.c:2743
#10 0xb77210ee in ruby_finalize_1 (ex=0) at eval.c:111
#11 ruby_cleanup (ex=0) at eval.c:161
#12 0xb772132d in ruby_run_node (n=0x8ac07e4) at eval.c:254
#13 0x080487d8 in main (argc=4, argv=0xbfa0ae84) at main.c:35
(gdb) info threads
  3 Thread 0xb7131b70 (LWP 6058)  0xb78b8424 in __kernel_vsyscall ()
  2 Thread 0xb6930b70 (LWP 6059)  0xb78b8424 in __kernel_vsyscall ()
* 1 Thread 0xb74ea6c0 (LWP 6056)  0xb78b8424 in __kernel_vsyscall ()
(gdb) thread 2
[Switching to thread 2 (Thread 0xb6930b70 (LWP 6059))]#0  0xb78b8424 in __kernel_vsyscall ()
(gdb) bt
#0  0xb78b8424 in __kernel_vsyscall ()
#1  0xb75b76f6 in epoll_wait () from /lib/i686/cmov/libc.so.6
#2  0xb72a90e6 in zmq::epoll_t::loop (this=0x8c8e688) at epoll.cpp:142
#3  0xb72c2426 in thread_routine (arg_=0x8c8e6cc) at thread.cpp:75
#4  0xb769c955 in start_thread () from /lib/i686/cmov/libpthread.so.0
#5  0xb75b6e7e in clone () from /lib/i686/cmov/libc.so.6
(gdb) thread 3
[Switching to thread 3 (Thread 0xb7131b70 (LWP 6058))]#0  0xb78b8424 in __kernel_vsyscall ()
(gdb) bt
#0  0xb78b8424 in __kernel_vsyscall ()
#1  0xb75b76f6 in epoll_wait () from /lib/i686/cmov/libc.so.6
#2  0xb72a90e6 in zmq::epoll_t::loop (this=0x8c95ce8) at epoll.cpp:142
#3  0xb72c2426 in thread_routine (arg_=0x8c95d2c) at thread.cpp:75
#4  0xb769c955 in start_thread () from /lib/i686/cmov/libpthread.so.0
#5  0xb75b6e7e in clone () from /lib/i686/cmov/libc.so.6
commented

Sry, my bad. It's ok.