]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[postprocessor/ffmpeg] Fix avconv processing broken in #19025 (closes #19067)
authorSergey M․ <dstftw@gmail.com>
Tue, 29 Jan 2019 23:15:23 +0000 (06:15 +0700)
committerSergey M․ <dstftw@gmail.com>
Tue, 29 Jan 2019 23:15:23 +0000 (06:15 +0700)
youtube_dl/postprocessor/ffmpeg.py

index 88b9ae9be36ce2a407b505d9960722406d91f0a4..5bcb00ac0daed0037d1d3f3978b1644e72a613a3 100644 (file)
@@ -217,11 +217,13 @@ class FFmpegPostProcessor(PostProcessor):
                 encodeArgument('-i'),
                 encodeFilename(self._ffmpeg_filename_argument(path), True)
             ])
-        cmd = ([encodeFilename(self.executable, True), encodeArgument('-y')] +
-               [encodeArgument('-loglevel'), encodeArgument('repeat+info')] +
-               files_cmd +
-               [encodeArgument(o) for o in opts] +
-               [encodeFilename(self._ffmpeg_filename_argument(out_path), True)])
+        cmd = [encodeFilename(self.executable, True), encodeArgument('-y')]
+        # avconv does not have repeat option
+        if self.basename == 'ffmpeg':
+            cmd += [encodeArgument('-loglevel'), encodeArgument('repeat+info')]
+        cmd += (files_cmd +
+                [encodeArgument(o) for o in opts] +
+                [encodeFilename(self._ffmpeg_filename_argument(out_path), True)])
 
         if self._downloader.params.get('verbose', False):
             self._downloader.to_screen('[debug] ffmpeg command line: %s' % shell_quote(cmd))