[#70257] [Ruby trunk - Feature #11420] [Open] Introduce ID key table into MRI — ko1@...

Issue #11420 has been reported by Koichi Sasada.

11 messages 2015/08/06

[ruby-core:70277] [Ruby trunk - Bug #11423] ruby_cleanup does not reset initialized flag

From: nobu@...
Date: 2015-08-09 05:15:11 UTC
List: ruby-core #70277
Issue #11423 has been updated by Nobuyoshi Nakada.

Description updated
Backport changed from 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN to 2.0.0: WONTFIX, 2.1: WONTFIX, 2.2: WONTFIX

That cycle is not guaranteed until MVM is supported.


----------------------------------------
Bug #11423: ruby_cleanup does not reset initialized flag
https://bugs.ruby-lang.org/issues/11423#change-53700

* Author: Alex Budovski
* Status: Open
* Priority: Normal
* Assignee: 
* ruby -v: 2.2.2
* Backport: 2.0.0: WONTFIX, 2.1: WONTFIX, 2.2: WONTFIX
----------------------------------------
`ruby_setup` checks for this static initialized to determine whether to run.

~~~c
int
ruby_setup(void)
{
    static int initialized = 0;
    int state;

    if (initialized)
	return 0;
    initialized = 1;
~~~

But `ruby_cleanup` fails to reset it, causing future initializations to do nothing. This means an embedded app which runs ruby scripts in a setup/run/cleanup cycle will crash the second time.



-- 
https://bugs.ruby-lang.org/

In This Thread

Prev Next