[fix] Ensure that arguments are passed to the hook as string

This commit is contained in:
Le Kload 2015-09-22 17:32:13 +02:00 committed by kload
parent 115df29afc
commit b2b1fc7d80

View file

@ -303,6 +303,7 @@ def hook_exec(file, args=None):
if arg_list:
# Concatenate arguments and escape them with double quotes to prevent
# bash related issue if an argument is empty and is not the last
arg_list = [str(s) for s in arg_list]
arg_str = '\\"{:s}\\"'.format('\\" \\"'.join(arg_list))
msignals.display(m18n.n('executing_script'))