summaryrefslogtreecommitdiff
path: root/data/_dpkg/runcmd.diff
diff options
context:
space:
mode:
Diffstat (limited to 'data/_dpkg/runcmd.diff')
-rw-r--r--data/_dpkg/runcmd.diff16
1 files changed, 16 insertions, 0 deletions
diff --git a/data/_dpkg/runcmd.diff b/data/_dpkg/runcmd.diff
new file mode 100644
index 000000000..dd2213d51
--- /dev/null
+++ b/data/_dpkg/runcmd.diff
@@ -0,0 +1,16 @@
+diff -ur dpkg-1.18.25/lib/dpkg/command.c dpkg-1.18.25+iPhone/lib/dpkg/command.c
+--- dpkg-1.18.25/lib/dpkg/command.c 2018-03-21 18:29:34.000000000 -1000
++++ dpkg-1.18.25+iPhone/lib/dpkg/command.c 2018-10-12 12:36:05.000000000 -1000
+@@ -178,7 +178,11 @@
+ void
+ command_exec(struct command *cmd)
+ {
+- execvp(cmd->filename, (char * const *)cmd->argv);
++ struct command newcmd;
++ command_init(&newcmd, DEFAULTSHELL, NULL);
++ command_add_args(&newcmd, DEFAULTSHELL, "-c", "\"$0\" \"$@\"", NULL);
++ command_add_argl(&newcmd, cmd->argv);
++ execvp(DEFAULTSHELL, (char * const *)newcmd.argv);
+ ohshite(_("unable to execute %s (%s)"), cmd->name, cmd->filename);
+ }
+