mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-21 05:43:16 -07:00
Fix for video corruption check issues
This commit is contained in:
parent
27d722e8b1
commit
9836562d8b
1 changed files with 5 additions and 5 deletions
|
@ -280,15 +280,15 @@ def initialize(section=None):
|
||||||
else:
|
else:
|
||||||
bitbucket = open('/dev/null')
|
bitbucket = open('/dev/null')
|
||||||
|
|
||||||
FFMPEG = subprocess.call(['which', 'ffmpeg'], stdout=bitbucket, stderr=bitbucket)
|
FFMPEG = subprocess.Popen(['which', 'ffmpeg'], stdout=subprocess.PIPE).communicate()[0]
|
||||||
FFPROBE = subprocess.call(['which', 'ffprobe'], stdout=bitbucket, stderr=bitbucket)
|
FFPROBE = subprocess.Popen(['which', 'ffprobe'], stdout=subprocess.PIPE).communicate()[0]
|
||||||
|
|
||||||
if not (FFMPEG or FFPROBE):
|
if not (FFMPEG or FFPROBE):
|
||||||
# Auto-install FFMPEG and FFPROBE
|
# Auto-install FFMPEG and FFPROBE
|
||||||
res = subprocess.call([joinPath(PROGRAM_DIR, 'getffmpeg.sh')], stdout=bitbucket, stderr=bitbucket)
|
res = subprocess.call([joinPath(PROGRAM_DIR, 'getffmpeg.sh')], stdout=bitbucket, stderr=bitbucket)
|
||||||
if res == 0: # did not install or ffmpeg still not found.
|
if res == 0:
|
||||||
FFMPEG = subprocess.call(['which', 'ffmpeg'], stdout=bitbucket, stderr=bitbucket)
|
FFMPEG = subprocess.Popen(['which', 'ffmpeg'], stdout=subprocess.PIPE).communicate()[0]
|
||||||
FFPROBE = subprocess.call(['which', 'ffprobe'], stdout=bitbucket, stderr=bitbucket)
|
FFPROBE = subprocess.Popen(['which', 'ffprobe'], stdout=subprocess.PIPE).communicate()[0]
|
||||||
else:
|
else:
|
||||||
logger.error("Failed to install ffmpeg. Please install manually")
|
logger.error("Failed to install ffmpeg. Please install manually")
|
||||||
FFMPEG = None
|
FFMPEG = None
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue