Open labmem005 opened 5 years ago
Could you provide an sample file containing CRLF ?
Hi together :-) I do have the same problem - f.i. with the attached srt. src.zip Reason is probably the BOM. Proposal: When doing
// First textLine is the cue number try { Integer.parseInt(textLine); } catch (NumberFormatException e) { throw new SubtitleParsingException(String.format( "Unable to parse cue number: %s", textLine)); }
Use this method to fix textLine:
private static String removeUTF8BOM(String s) { if (s != null && s.startsWith(UTF8_BOM)) { s = s.substring(1); } return s; }
with
private static final String UTF8_BOM = "\uFEFF";
Sorry if this is not the proper way to contribute, it is my first day at Github - and it is FRIDAY!
@missesProper Thank you!get it \^O^/
:octocat: From gitme Android
A file write with 'CRLF' can't parse. SubtitleParsingException: Unable to parse cue number: 1