downloads: replace placeholder in cmdline

This allows commands like --file={} to work properly.
This commit is contained in:
Daniel Schadt 2016-08-03 10:25:14 +02:00
parent a85227fa25
commit e8bfc25bbc

View File

@ -553,7 +553,7 @@ class DownloadItem(QObject):
return
cmd, *args = shlex.split(cmdline)
args = [filename if arg == '{}' else arg for arg in args]
args = [arg.replace('{}', filename) for arg in args]
log.downloads.debug("Opening {} with {}"
.format(filename, [cmd] + args))
proc = guiprocess.GUIProcess(self._win_id, what='download')