This change addresses a hang/segfault in TestEvents.py. The threads that run the listener loops now do an SBListener.Clear() before they wrap up their work. This prevents the test from trying to clean up the SBListener too late.
There is a separate issue here which is that we should prevent this clean-up time lock-up, but that is out of scope for this particular change. I'd like to get these tests back and running the normal flow rather than skipping them.
This addresses:
llvm.org/pr25924 (at least, the OS X side, although I suspect this will also address Linux)