Fix thread classes init. Minor fixes.