projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
577281b
)
[extractor/common] Fix Bandwidth substitution in media template (closes #11175)
author
Sergey M․
<dstftw@gmail.com>
Sat, 12 Nov 2016 22:43:34 +0000
(
05:43
+0700)
committer
Sergey M․
<dstftw@gmail.com>
Sat, 12 Nov 2016 22:43:34 +0000
(
05:43
+0700)
youtube_dl/extractor/common.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/common.py
b/youtube_dl/extractor/common.py
index bc5d6a4c3d1f84ef54728af4029131caeb00d6be..05c51fac9b0b4162fb126cb79a79d871b591ead8 100644
(file)
--- a/
youtube_dl/extractor/common.py
+++ b/
youtube_dl/extractor/common.py
@@
-1703,7
+1703,7
@@
class InfoExtractor(object):
representation_ms_info['fragments'] = [{
'url': media_template % {
'Number': segment_number,
representation_ms_info['fragments'] = [{
'url': media_template % {
'Number': segment_number,
- 'Bandwidth':
representation_attrib.get('bandwidth'
),
+ 'Bandwidth':
int_or_none(representation_attrib.get('bandwidth')
),
},
'duration': segment_duration,
} for segment_number in range(
},
'duration': segment_duration,
} for segment_number in range(
@@
-1721,7
+1721,7
@@
class InfoExtractor(object):
def add_segment_url():
segment_url = media_template % {
'Time': segment_time,
def add_segment_url():
segment_url = media_template % {
'Time': segment_time,
- 'Bandwidth':
representation_attrib.get('bandwidth'
),
+ 'Bandwidth':
int_or_none(representation_attrib.get('bandwidth')
),
'Number': segment_number,
}
representation_ms_info['fragments'].append({
'Number': segment_number,
}
representation_ms_info['fragments'].append({