updated time out error and added error close signal