Major Bugfixes

Long story short: I do not know how to properly close threads.