Project

General

Profile

Actions

Bug #9628

closed

Simple and isolated segfault in 2.1.0 and 2.1.1 on Mac OS X 10.9.2 (via rbenv)

Added by tmornini (Tom Mornini) almost 11 years ago. Updated over 5 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 2.1.1p76 (2014-02-24 revision 45161) [x86_64-darwin13.0] and ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-darwin13.0]
Backport:
[ruby-core:61443]

Description

Example code and output for 2.0.0-p451, 2.1.0 and 2.1.1:

https://gist.github.com/tmornini/9518056

Code:

#!/usr/bin/env ruby

module Subledger
class Error < StandardError
def to_s
"#{message}, HTTP status #{status_code}"
end
end

class BadRequest < Error
def status_code; 400; end
end

fail BadRequest, 'explanation'
end

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0