multithreading bugfix