commit 2f4d18a9f78f9d18635c6047e56b33c689b8d026
parent b0eddb2eb4b8cad325ba3224c8550a21f67e4315
Author: Ricardo Garcia <sarbalap+freshmeat@gmail.com>
Date: Wed, 22 Apr 2009 22:57:21 +0200
Use getpreferredencoding() instead of getdefaultlocale()
This fixes issue #7 and is recommended after a bug report I made to the
Python team:
http://bugs.python.org/issue5815
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/youtube-dl b/youtube-dl
@@ -1056,7 +1056,7 @@ if __name__ == '__main__':
youtube_search_ie = YoutubeSearchIE(youtube_ie)
# File downloader
- charset = locale.getdefaultlocale()[1]
+ charset = locale.getpreferredencoding()
if charset is None:
charset = 'ascii'
fd = FileDownloader({