Made sure TaskProcessor's running status initializes to false and added done call after the TaskProcessor stop in main.