ignore anything after timecodes in srt, fixes #996
This commit is contained in:
parent
1522f870b7
commit
2d1ad2785d
1 changed files with 1 additions and 1 deletions
|
@ -75,7 +75,7 @@ def load(filename, offset=0):
|
|||
return srt
|
||||
|
||||
data = data.replace('\r\n', '\n')
|
||||
srts = re.compile('(\d\d:\d\d:\d\d[,.]\d\d\d)\s*?-->\s*?(\d\d:\d\d:\d\d[,.]\d\d\d)\s*?(.*?)\n\n', re.DOTALL)
|
||||
srts = re.compile('(\d\d:\d\d:\d\d[,.]\d\d\d)\s*?-->\s*?(\d\d:\d\d:\d\d[,.]\d\d\d).*?\n(.*?)\n\n', re.DOTALL)
|
||||
i = 0
|
||||
for s in srts.findall(data):
|
||||
_s = {'id': str(i),
|
||||
|
|
Loading…
Reference in a new issue