mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-22 06:13:19 -07:00
don't pass -p for gunzip #1715
This commit is contained in:
parent
d8ac655266
commit
5359260996
1 changed files with 3 additions and 2 deletions
|
@ -131,14 +131,15 @@ def extract(file_path, output_destination):
|
|||
else:
|
||||
cmd = core.NICENESS + cmd
|
||||
cmd2 = cmd
|
||||
cmd2.append('-p-') # don't prompt for password.
|
||||
if not 'gunzip' in cmd: #gunzip doesn't support password
|
||||
cmd2.append('-p-') # don't prompt for password.
|
||||
p = Popen(cmd2, stdout=devnull, stderr=devnull, startupinfo=info) # should extract files fine.
|
||||
res = p.wait()
|
||||
if res == 0: # Both Linux and Windows return 0 for successful.
|
||||
core.logger.info('EXTRACTOR: Extraction was successful for {file} to {destination}'.format
|
||||
(file=file_path, destination=output_destination))
|
||||
success = 1
|
||||
elif len(passwords) > 0:
|
||||
elif len(passwords) > 0 and not 'gunzip' in cmd:
|
||||
core.logger.info('EXTRACTOR: Attempting to extract with passwords')
|
||||
for password in passwords:
|
||||
if password == '': # if edited in windows or otherwise if blank lines.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue