fix all errors add open files