fixed multi thread creation