From 9d4288b2d4a47d36a2a8fa116f1023251e436cdc Mon Sep 17 00:00:00 2001 From: Philipp Hagemeister Date: Tue, 21 Jan 2014 01:41:13 +0100 Subject: [PATCH] [extractor/common] Clarify when and when not we generate the filename --- youtube_dl/extractor/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index 6c5d77e58..582eb4f5b 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -238,7 +238,7 @@ def _download_webpage_handle(self, url_or_request, video_id, note=None, errnote= except AttributeError: url = url_or_request if len(url) > 200: - h = hashlib.md5(url).hexdigest() + h = u'___' + hashlib.md5(url).hexdigest() url = url[:200 - len(h)] + h raw_filename = ('%s_%s.dump' % (video_id, url)) filename = sanitize_filename(raw_filename, restricted=True)