[#79440] [Ruby trunk Bug#13188] Reinitialize Ruby VM. — shyouhei@...
Issue #13188 has been updated by Shyouhei Urabe.
6 messages
2017/02/06
[#79441] Re: [Ruby trunk Bug#13188] Reinitialize Ruby VM.
— SASADA Koichi <ko1@...>
2017/02/06
On 2017/02/06 10:10, shyouhei@ruby-lang.org wrote:
[#79532] Immutable Strings vs Symbols — Daniel Ferreira <subtileos@...>
Hi,
15 messages
2017/02/15
[#79541] Re: Immutable Strings vs Symbols
— Rodrigo Rosenfeld Rosas <rr.rosas@...>
2017/02/15
Em 15-02-2017 05:05, Daniel Ferreira escreveu:
[#79543] Re: Immutable Strings vs Symbols
— Daniel Ferreira <subtileos@...>
2017/02/16
Hi Rodrigo,
[#79560] Re: Immutable Strings vs Symbols
— Rodrigo Rosenfeld Rosas <rr.rosas@...>
2017/02/16
Em 15-02-2017 22:39, Daniel Ferreira escreveu:
[ruby-core:79582] [Ruby trunk Bug#13223] `File.join` will segv if File::SEPARATOR and File::Separator are set.
From:
nobu@...
Date:
2017-02-18 01:48:43 UTC
List:
ruby-core #79582
Issue #13223 has been updated by Nobuyoshi Nakada. Description updated I doubt that the tests are expected results. And a similar pattern: ```ruby $; = " " $a = nil alias $; $a alias $-F $a GC.start "".split ``` ---------------------------------------- Bug #13223: `File.join` will segv if File::SEPARATOR and File::Separator are set. https://bugs.ruby-lang.org/issues/13223#change-63012 * Author: Aaron Patterson * Status: Open * Priority: Normal * Assignee: * Target version: * ruby -v: ruby 2.5.0dev (2017-02-17 trunk 57648) [x86_64-darwin16] * Backport: 2.2: UNKNOWN, 2.3: UNKNOWN, 2.4: UNKNOWN ---------------------------------------- The program below will crash with a segv: ~~~ruby File.const_set :Separator, "hello" File.const_set :SEPARATOR, "hello" GC.start File.join "hello", "world" ~~~ This is because the separator object is referenced from a global variable and setting the constants allows the object to be GC'd and the global will go bad. I've attached a patch that contains a test to demonstrate the problem along with a fix. ---Files-------------------------------- 0001-Fix-segv-in-File.join-when-SEPARATOR-and-Separator-a.patch (3.04 KB) -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>