]> git.bitcoin.ninja Git - youtube-dl/commitdiff
Python 2.6 compatibility fix. Thanks @Jamesc359 - closes #400
authorFilippo Valsorda <filippo.valsorda@gmail.com>
Sun, 19 Aug 2012 14:06:33 +0000 (16:06 +0200)
committerFilippo Valsorda <filippo.valsorda@gmail.com>
Sun, 19 Aug 2012 14:06:33 +0000 (16:06 +0200)
youtube-dl
youtube_dl/utils.py

index f2268af227b0eee8548aa6d106861cc508879931..789cb58f53739e4931ca05425c26f6f87b0fff8c 100755 (executable)
Binary files a/youtube-dl and b/youtube-dl differ
index 2853ba50f228bb1f87900aa78a256b1637fcee2b..922e17eccfac611a1d90bf83e913383c9afce30d 100644 (file)
@@ -223,7 +223,7 @@ def encodeFilename(s):
 
        assert type(s) == type(u'')
 
-       if sys.platform == 'win32' and sys.getwindowsversion().major >= 5:
+       if sys.platform == 'win32' and sys.getwindowsversion()[0] >= 5:
                # Pass u'' directly to use Unicode APIs on Windows 2000 and up
                # (Detecting Windows NT 4 is tricky because 'major >= 4' would
                # match Windows 9x series as well. Besides, NT 4 is obsolete.)