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

ruby-changes:17321

From: nobu <ko1@a...>
Date: Thu, 23 Sep 2010 23:09:28 +0900 (JST)
Subject: [ruby-changes:17321] Ruby:r29325 (trunk): * vm_insnhelper.c (vm_get_cref0): cref is stacked only in normal

nobu	2010-09-23 23:09:22 +0900 (Thu, 23 Sep 2010)

  New Revision: 29325

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

  Log:
    * vm_insnhelper.c (vm_get_cref0): cref is stacked only in normal
      iseqs, so check if it is the case first.

  Modified files:
    trunk/ChangeLog
    trunk/vm_insnhelper.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 29324)
+++ ChangeLog	(revision 29325)
@@ -1,3 +1,8 @@
+Thu Sep 23 23:09:08 2010  Nobuyoshi Nakada  <nobu@r...>
+
+	* vm_insnhelper.c (vm_get_cref0): cref is stacked only in normal
+	  iseqs, so check if it is the case first.
+
 Thu Sep 23 23:08:41 2010  Nobuyoshi Nakada  <nobu@r...>
 
 	* tool/config.sub: mingw64 should use x86_64.  [ruby-core:32514]
Index: vm_insnhelper.c
===================================================================
--- vm_insnhelper.c	(revision 29324)
+++ vm_insnhelper.c	(revision 29325)
@@ -1057,6 +1057,7 @@
 {
     while (1) {
 	if (lfp == dfp) {
+	    if (!RUBY_VM_NORMAL_ISEQ_P(iseq)) return NULL;
 	    return iseq->cref_stack;
 	}
 	else if (dfp[-1] != Qnil) {

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

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