Project

General

Profile

Actions

Bug #4488

closed

Segmentation fault when calling new (or in rspec)

Added by levsa (Levon Saldamli) about 13 years ago. Updated over 11 years ago.

Status:
Third Party's Issue
Assignee:
-
Target version:
-
ruby -v:
ruby 1.9.2p136 (2010-12-25) [i386-mingw32]
Backport:
[ruby-core:<unknown>]

Description

=begin
def Session.instance(*args, &block)
@instance ||= new(*args, &block) # this line seems to trigger a segfault
end

when called from:

it "should fail on an invalid application key" do
  expect { Hallon::Session.instance('invalid') }.to raise_error(Hallon::Error)
end

=end


Files

err.log (8.17 KB) err.log stderr levsa (Levon Saldamli), 03/10/2011 08:24 AM
out.log (129 Bytes) out.log stdout levsa (Levon Saldamli), 03/10/2011 08:24 AM

Updated by naruse (Yui NARUSE) almost 13 years ago

  • Status changed from Open to Feedback

Would you show a reproducible code?

Updated by mame (Yusuke Endoh) over 11 years ago

  • Status changed from Feedback to Third Party's Issue

I succeeded to repro:

$ gem install hallon
$ ruby -rhallon -e 'def (Hallon::Session).instance(*args, &block); @instance ||= new(*args, &block); end; Hallon::Session.instance("invalid")'
/home/mame/work/local/lib/ruby/gems/2.0.0/gems/spotify-12.3.0/lib/spotify.rb:99: [BUG] Segmentation fault
ruby 2.0.0dev (2012-10-12 trunk 37163) [x86_64-linux]

snip

-- C level backtrace information -------------------------------------------
/home/mame/work/local/bin/ruby(+0x151aa8) [0x7f84357ebaa8]
/home/mame/work/local/bin/ruby(+0x1aa487) [0x7f8435844487]
/home/mame/work/local/bin/ruby(rb_bug+0xb3) [0x7f8435845b13]
/home/mame/work/local/bin/ruby(+0xd944c) [0x7f843577344c]
/lib/x86_64-linux-gnu/libpthread.so.0(+0xfcb0) [0x7f8435267cb0] AbstractMemory.c:268
/home/mame/work/local/lib/ruby/gems/2.0.0/gems/libspotify-12.1.51.1-x86_64-linux/libspotify.library(sp_session_create+0x546) [0x7f84331203b9] dir.c:1383

snip

This trace strongly suggests that this issue is a fault of libspotify.
The source of libspotify looks unavailable, so we can no longer investigate this issue.
Could you please contact Spotify?
If they say this is a ruby fault, please ask them to disclose their source code.

--
Yusuke Endoh

Actions

Also available in: Atom PDF

Like0
Like0Like0