Fix in thread creation.