OSDN Git Service

Fix issue with Thread.setName hanging after Thread.start
authorBrian Carlstrom <bdc@google.com>
Thu, 28 Aug 2014 06:43:46 +0000 (23:43 -0700)
committerBrian Carlstrom <bdc@google.com>
Thu, 28 Aug 2014 22:37:27 +0000 (15:37 -0700)
commitba32de47e32f436d7c11cb4a2e78bdd4ad4dc5d2
tree1b56397dfce317d2034feebfb2191bcb09b78823
parent14515d738dadf88e3e00b7dd1bd69899c4df4b91
Fix issue with Thread.setName hanging after Thread.start

When suspending a thread by peer the invariant that only attached threads are
suspended must be maintained. Add a ThreadList::Contains check which requires
making this method non-static.
Add some extra thread logging.

Bug: 17302037

(cherry picked from commit 37c16453a92bbf1a47f042000318a1b60381017d)

Change-Id: I51832785d4b4b431e035318e75635f442e89a1fb
runtime/debugger.cc
runtime/native/dalvik_system_VMStack.cc
runtime/native/java_lang_Thread.cc
runtime/thread_list.cc
runtime/thread_list.h
test/051-thread/expected.txt
test/051-thread/src/Main.java