[前][次][番号順一覧][スレッド一覧]

ruby-changes:26697

From: nobu <ko1@a...>
Date: Wed, 9 Jan 2013 15:40:40 +0900 (JST)
Subject: [ruby-changes:26697] nobu:r38748 (trunk): vm.c: initialize root_svar

nobu	2013-01-09 15:40:30 +0900 (Wed, 09 Jan 2013)

  New Revision: 38748

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=38748

  Log:
    vm.c: initialize root_svar
    
    * vm.c (th_init, ruby_thread_init): initialize root_svar with Qnil,
      since lep_svar_place() expects uninitialized svar to be nil, not 0.

  Modified files:
    trunk/ChangeLog
    trunk/vm.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 38747)
+++ ChangeLog	(revision 38748)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Jan  9 15:40:18 2013  Nobuyoshi Nakada  <nobu@r...>
+
+	* vm.c (th_init, ruby_thread_init): initialize root_svar with Qnil,
+	  since lep_svar_place() expects uninitialized svar to be nil, not 0.
+
 Wed Jan  9 13:20:23 2013  Masaki Matsushita  <glass.saga@g...>
 
 	* test/ruby/test_require.rb: improve test for r38744.
Index: vm.c
===================================================================
--- vm.c	(revision 38747)
+++ vm.c	(revision 38748)
@@ -1930,6 +1930,7 @@ th_init(rb_thread_t *th, VALUE self) https://github.com/ruby/ruby/blob/trunk/vm.c#L1930
     th->errinfo = Qnil;
     th->last_status = Qnil;
     th->waiting_fd = -1;
+    th->root_svar = Qnil;
 
 #if OPT_CALL_THREADED_CODE
     th->retval = Qundef;
@@ -1949,6 +1950,7 @@ ruby_thread_init(VALUE self) https://github.com/ruby/ruby/blob/trunk/vm.c#L1950
 
     th->top_wrapper = 0;
     th->top_self = rb_vm_top_self();
+    th->root_svar = Qnil;
     return self;
 }
 

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]