Use shlex.split for --pp-params and update related docs.
[youtube-dl] / youtube_dl / __init__.py
index 5b28e48179ddb19b4134d07cd1d2cf0d3dd4e1b0..8b54d4ae2c6cac6e0f7b5b10fb1e9ee609412100 100644 (file)
@@ -171,8 +171,10 @@ def _real_main(argv=None):
     if opts.recodevideo is not None:
         if opts.recodevideo not in ['mp4', 'flv', 'webm', 'ogg', 'mkv', 'xvid']:
             parser.error('invalid video recode format specified')
-    if opts.pp_params is not None:
-        opts.pp_params = opts.pp_params.split()
+    if opts.pp_params is None:
+        opts.pp_params = []
+    else:
+        opts.pp_params = shlex.split(opts.pp_params)
     if opts.convertsubtitles is not None:
         if opts.convertsubtitles not in ['srt', 'vtt', 'ass']:
             parser.error('invalid subtitle format specified')