fix for Thread::TryJoin on linux