Index: runtime/bin/thread_win.cc |
diff --git a/runtime/bin/thread_win.cc b/runtime/bin/thread_win.cc |
index db4119604000d64ae30868b7fb32514ae9e30212..b8b73dc442c8244310146e7fa4fab0a7646d07a5 100644 |
--- a/runtime/bin/thread_win.cc |
+++ b/runtime/bin/thread_win.cc |
@@ -104,23 +104,7 @@ ThreadId Thread::GetCurrentThreadId() { |
bool Thread::Join(ThreadId id) { |
- HANDLE handle = OpenThread(SYNCHRONIZE, false, id); |
- |
- // TODO(zra): OSThread::Start() closes the handle to the thread. Thus, by the |
- // time we try to join the thread, its resources may have already been |
- // reclaimed, and joining will fail. This can be avoided in a couple of ways. |
- // First, GetCurrentThreadJoinId could call OpenThread and return a handle. |
- // This is bad, because each of those handles would have to be closed. |
- // Second OSThread could be refactored to no longer be AllStatic. Then the |
- // handle could be cached in the object by the Start method. |
- if (handle == NULL) { |
- return false; |
- } |
- |
- DWORD res = WaitForSingleObject(handle, INFINITE); |
- CloseHandle(handle); |
- ASSERT(res == WAIT_OBJECT_0); |
- return true; |
+ return false; |
} |
siva
2016/05/16 17:59:27
The Thread::Join function doesn't seem to be used
zra
2016/05/16 20:32:54
Done.
|