From 91d59c7be72ef6f6ce5d41b2b2fc26b18ffb9e59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rog=C3=A9rio=20Brito?= Date: Mon, 25 Feb 2013 22:13:40 -0300 Subject: [PATCH] FileDownloader: aria2c: Add path to cookies file on if it exists. --- youtube_dl/FileDownloader.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/youtube_dl/FileDownloader.py b/youtube_dl/FileDownloader.py index 631a33c22..abc278ce5 100644 --- a/youtube_dl/FileDownloader.py +++ b/youtube_dl/FileDownloader.py @@ -648,7 +648,10 @@ class FileDownloader(object): basic_args += ['--min-split-size', '1M'] basic_args += ['--max-connection-per-server', '4'] basic_args += ['--user-agent', std_headers['User-Agent']] - basic_args += ['--load-cookies=' + tmp_jar_name ] + + if tmp_jar_name: + basic_args += ['--load-cookies=' + tmp_jar_name ] + basic_args += ['-o', filename, url] retval = subprocess.call(basic_args)