Corrections of errors for invalid formats and invalid segments