mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-21 22:03:13 -07:00
Sending ffmpeg checks for executables to null
This commit is contained in:
parent
00a5dae4e3
commit
334d213055
1 changed files with 4 additions and 2 deletions
|
@ -277,10 +277,12 @@ def initialize(section=None):
|
||||||
FFPROBE = None
|
FFPROBE = None
|
||||||
|
|
||||||
else:
|
else:
|
||||||
|
bitbucket = open('/dev/null')
|
||||||
|
|
||||||
FFMPEG = 'ffmpeg'
|
FFMPEG = 'ffmpeg'
|
||||||
FFPROBE = 'ffprobe'
|
FFPROBE = 'ffprobe'
|
||||||
if subprocess.call(['which', 'ffmpeg']) != 0:
|
if subprocess.call(['which', 'ffmpeg']) != 0:
|
||||||
res = subprocess.call([os.path.join(PROGRAM_DIR, 'getffmpeg.sh')])
|
res = subprocess.call([os.path.join(PROGRAM_DIR, 'getffmpeg.sh')], stdout=bitbucket, stderr=bitbucket)
|
||||||
if res or subprocess.call(['which', 'ffmpeg']) != 0: # did not install or ffmpeg still not found.
|
if res or subprocess.call(['which', 'ffmpeg']) != 0: # did not install or ffmpeg still not found.
|
||||||
logger.error("Failed to install ffmpeg. Please install manually")
|
logger.error("Failed to install ffmpeg. Please install manually")
|
||||||
logger.info("Cannot transcode video files, disabling transcoding!")
|
logger.info("Cannot transcode video files, disabling transcoding!")
|
||||||
|
@ -288,7 +290,7 @@ def initialize(section=None):
|
||||||
FFMPEG = None
|
FFMPEG = None
|
||||||
|
|
||||||
if subprocess.call(['which', 'ffprobe']) != 0:
|
if subprocess.call(['which', 'ffprobe']) != 0:
|
||||||
res = subprocess.call([os.path.join(PROGRAM_DIR, 'getffmpeg.sh')])
|
res = subprocess.call([os.path.join(PROGRAM_DIR, 'getffmpeg.sh')], stdout=bitbucket, stderr=bitbucket)
|
||||||
if res or subprocess.call(['which', 'ffprobe']) != 0:
|
if res or subprocess.call(['which', 'ffprobe']) != 0:
|
||||||
logger.error("Failed to install ffprobe. Please install manually")
|
logger.error("Failed to install ffprobe. Please install manually")
|
||||||
logger.info("Cannot detect corrupt video files, disabling corrupt video detection!")
|
logger.info("Cannot detect corrupt video files, disabling corrupt video detection!")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue