The thread plan destructors may call Thread virtual methods.  That means they have to get cleaned up in the derived class's destructor.  Make sure that happens.

git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@119675 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp b/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp
index 6ee1406..c1b5fa4 100644
--- a/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp
+++ b/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp
@@ -48,6 +48,7 @@
 ThreadGDBRemote::~ThreadGDBRemote ()
 {
     ProcessGDBRemoteLog::LogIf(GDBR_LOG_THREAD, "%p: ThreadGDBRemote::~ThreadGDBRemote (pid = %i, tid = 0x%4.4x)", this, m_process.GetID(), GetID());
+    DestroyThread();
 }