parsing error cleanup