090be3
From 428791543be9e13af9426970f5796f3157dd30a0 Mon Sep 17 00:00:00 2001
090be3
From: nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>
090be3
Date: Tue, 9 Dec 2014 01:16:27 +0000
090be3
Subject: [PATCH] thread.c: get rid of invalid ID symbol
090be3
090be3
* eval.c (rb_frame_last_func): return the most recent frame method
090be3
  name.
090be3
* thread.c (recursive_list_access): use the last method name,
090be3
  instead of the current method name which can be unset in some
090be3
  cases, not to use a symbol by the invalid ID.
090be3
  [ruby-core:66742] [Bug #10579]
090be3
090be3
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48744 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
090be3
---
090be3
 ChangeLog                     | 10 ++++++++++
090be3
 eval.c                        | 13 +++++++++++++
090be3
 test/ruby/test_objectspace.rb |  7 +++++++
090be3
 thread.c                      |  5 ++++-
090be3
 4 files changed, 34 insertions(+), 1 deletion(-)
090be3
090be3
diff --git a/thread.c b/thread.c
090be3
index 25cc214..360c6cb 100644
090be3
--- a/thread.c
090be3
+++ b/thread.c
090be3
@@ -4671,6 +4671,8 @@ threadptr_recursive_hash_set(rb_thread_t *th, VALUE hash)
090be3
 /* variables for recursive traversals */
090be3
 static ID recursive_key;
090be3
 
090be3
+ID rb_frame_last_func(void);
090be3
+
090be3
 /*
090be3
  * Returns the current "recursive list" used to detect recursion.
090be3
  * This list is a hash table, unique for the current thread and for