Again, it works fine once I fixed the plugin.
The problem is that subprocess.Popen expects either:
- a list, and shell=False (shell defaults to false)
- a string, and shell=True
Passing a list to the shell means it tries to execute "jpegtran" and pass the additional arguments as arguments
to the shell itself, not jpegtran.
And yes, when you run
it hangs.
Why on earth does it specifically need a shell? The plugin isn't using shell builtins, pipes, variable expansion, tilde expansion, or shell globbing. Plus it is now vulnerable to shell injection (not that this is the easiest way to mess with someone's computer and make them run malicious commands, but still, it's the theory of the thing...)