Fixed exception handling in IOController.