Made the splitter thread more robust