瀏覽代碼

[utils] Clarify for redirecting STDIN in get_exe_version()

Yen Chi Hsuan 9 年之前
父節點
當前提交
b64d04c119
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      youtube_dl/utils.py

+ 3 - 0
youtube_dl/utils.py

@@ -1818,6 +1818,9 @@ def get_exe_version(exe, args=['--version'],
     """ Returns the version of the specified executable,
     or False if the executable is not present """
     try:
+        # STDIN should be redirected too. On UNIX-like systems, ffmpeg triggers
+        # SIGTTOU if youtube-dl is run in the background.
+        # See https://github.com/rg3/youtube-dl/issues/955#issuecomment-209789656
         out, _ = subprocess.Popen(
             [encodeArgument(exe)] + args,
             stdin=subprocess.PIPE,