aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2016-11-02 02:21:43 +0700
committerSergey M․ <dstftw@gmail.com>2016-11-02 02:30:25 +0700
commit1616f9b4525b8db229c162c21681e3c75abe4ce3 (patch)
treef9f7f5dcff7df4eccd3183e3b6c303e490a174bf /youtube_dl
parent02dc0a36b72b7312996d59b9ec96768f925cb4a4 (diff)
[extractor/common] Fix typo
Diffstat (limited to 'youtube_dl')
-rw-r--r--youtube_dl/extractor/common.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py
index 140ccf234..7e01c5fbb 100644
--- a/youtube_dl/extractor/common.py
+++ b/youtube_dl/extractor/common.py
@@ -1839,10 +1839,10 @@ class InfoExtractor(object):
next_fragment_time = int(stream_fragment[stream_fragment_index + 1].attrib['t'])
except IndexError:
next_fragment_time = duration
- fragment_ctx['duration'] = (next_fragment_time - frgament_time) / fragment_repeat
+ fragment_ctx['duration'] = (next_fragment_time - fragment_ctx['time']) / fragment_repeat
for _ in range(fragment_repeat):
fragments.append({
- 'url': re.sub(r'{start[ _]time}', str(fragment_ctx['time']), track_url_pattern),
+ 'url': re.sub(r'{start[ _]time}', compat_str(fragment_ctx['time']), track_url_pattern),
'duration': fragment_ctx['duration'] / stream_timescale,
})
fragment_ctx['time'] += fragment_ctx['duration']