From: nobu@... Date: 2014-08-31T23:50:50+00:00 Subject: [ruby-core:64695] [ruby-trunk - Bug #10190] Segmentation fault when Thread::Queue#push is called through dRuby Issue #10190 has been updated by Nobuyoshi Nakada. Duplicates Bug #9674: Segfault when marshaling Queue added ---------------------------------------- Bug #10190: Segmentation fault when Thread::Queue#push is called through dRuby https://bugs.ruby-lang.org/issues/10190#change-48593 * Author: Yuichi TANIKAWA * Status: Open * Priority: Normal * Assignee: * Category: * Target version: * ruby -v: ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux] * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN ---------------------------------------- I found a segmentation fault when `Thread::Queue` is attached to a dRuby server as a front object and `#push` is called from a dRuby client. Here are programs, a procedure and logs. ## server.rb ~~~ require 'drb/drb' require 'thread' q = Queue.new DRb.start_service('druby://localhost:12345', q) DRb.thread.join ~~~ ## client.rb ~~~ require 'drb/drb' require 'thread' DRb.start_service q = DRbObject.new_with_uri('druby://localhost:12345') q.push 1 ~~~ ## procedure ~~~ $ ruby server.rb # in another terminal $ ruby client.rb ~~~ ## server.rb log ~~~ /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:562: [BUG] Segmentation fault at 0x00000000000018 ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux] ~~~ ## client.rb log ~~~ /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:575:in `load': connection closed (DRb::DRbConnError) from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:637:in `recv_reply' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:936:in `recv_reply' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1222:in `send_message' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1110:in `block (2 levels) in method_missing' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1197:in `open' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1109:in `block in method_missing' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1128:in `with_friend' from /home/itiut/.linuxbrew/var/rbenv/versions/2.1.2/lib/ruby/2.1.0/drb/drb.rb:1108:in `method_missing' from client.rb:5:in `
' ~~~ I tried executing the procedure many times but the server's log contained detailed information only once or twice. Fortunately I found it in a terminal scrollback buffer, so I attach it. ---Files-------------------------------- server.log (13.8 KB) -- https://bugs.ruby-lang.org/