handle srts with empty lines at end of file