]> gitweb @ CieloNegro.org - youtube-dl.git/commitdiff
[youtube] Fix acodec and vcodec order
authorYen Chi Hsuan <yan12125@gmail.com>
Wed, 13 Jan 2016 09:05:38 +0000 (17:05 +0800)
committerYen Chi Hsuan <yan12125@gmail.com>
Wed, 13 Jan 2016 09:05:38 +0000 (17:05 +0800)
In RFC6381, there's no rule stating that the first part of codecs should
be video and the second part should be audio, while it seems the case
for data reported by YouTube.

youtube_dl/extractor/youtube.py

index 897641e4283d0c3423adfb47c067f7be03b79cf7..e4f227f199d10ae3923acbc97d09263a9531470a 100644 (file)
@@ -1487,7 +1487,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
                             if codecs:
                                 codecs = codecs.split(',')
                                 if len(codecs) == 2:
-                                    acodec, vcodec = codecs[0], codecs[1]
+                                    acodec, vcodec = codecs[1], codecs[0]
                                 else:
                                     acodec, vcodec = (codecs[0], 'none') if kind == 'audio' else ('none', codecs[0])
                                 dct.update({