mirror of
https://github.com/samsonjs/media.git
synced 2026-04-12 12:25:47 +00:00
Fix possible subrip timing line NPE
This commit is contained in:
parent
44fa0b446e
commit
85d6c0f0a9
1 changed files with 2 additions and 2 deletions
|
|
@ -69,8 +69,8 @@ public final class SubripDecoder extends SimpleSubtitleDecoder {
|
|||
// Read and parse the timing line.
|
||||
boolean haveEndTimecode = false;
|
||||
currentLine = subripData.readLine();
|
||||
Matcher matcher = SUBRIP_TIMING_LINE.matcher(currentLine);
|
||||
if (matcher.matches()) {
|
||||
Matcher matcher = currentLine == null ? null : SUBRIP_TIMING_LINE.matcher(currentLine);
|
||||
if (matcher != null && matcher.matches()) {
|
||||
cueTimesUs.add(parseTimecode(matcher, 1));
|
||||
if (!TextUtils.isEmpty(matcher.group(6))) {
|
||||
haveEndTimecode = true;
|
||||
|
|
|
|||
Loading…
Reference in a new issue