MouseDownThread: let thread terminate cleanly.

* Killing the thread leaks resources, and it will terminate cleanly and
safely when the destructor exits anyway.
* Fixes #12293. Thanks to ttcoder, jackburton and bonefish for investigating!
* Does not fix #12286. Going to bissect now...
This commit is contained in:
Adrien Destugues 2015-08-07 20:37:11 +02:00
parent f6f96d9689
commit 3749038b53

View File

@ -365,11 +365,6 @@ MouseDownThread<View>::MouseDownThread(View* view,
template<class View>
MouseDownThread<View>::~MouseDownThread()
{
if (fThreadID > 0) {
kill_thread(fThreadID);
// dead at this point
TRESPASS();
}
}
@ -393,7 +388,6 @@ MouseDownThread<View>::TrackBinder(void* castToThis)
MouseDownThread* self = static_cast<MouseDownThread*>(castToThis);
self->Track();
// dead at this point
TRESPASS();
return B_OK;
}
@ -427,9 +421,9 @@ MouseDownThread<View>::Track()
}
delete this;
ASSERT(!"should not be here");
}
} // namespace BPrivate
using namespace BPrivate;