summaryrefslogtreecommitdiff
path: root/diff.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2009-12-30 06:01:09 -0500
committerJunio C Hamano <gitster@pobox.com>2010-01-05 23:41:51 -0800
commit41a457e4f814a0e514548b3178e7692129f0fcfe (patch)
tree3b1a66dac76d179328110fe33c92f728ce7410e2 /diff.c
parentbac8037081735a49bccdc3b3b1457129f9bcc451 (diff)
downloadgit-41a457e4f814a0e514548b3178e7692129f0fcfe.tar.gz
textconv: use shell to run helper
Currently textconv helpers are run directly. Running through the shell is useful because the user can provide a program with command line arguments, like "antiword -f". It also makes textconv more consistent with other parts of git, most of which run their helpers using the shell. The downside is that textconv helpers with shell metacharacters (like space) in the filename will be broken. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff.c')
-rw-r--r--diff.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/diff.c b/diff.c
index 08bbd3e907..4af7c3f925 100644
--- a/diff.c
+++ b/diff.c
@@ -3771,6 +3771,7 @@ static char *run_textconv(const char *pgm, struct diff_filespec *spec,
*arg = NULL;
memset(&child, 0, sizeof(child));
+ child.use_shell = 1;
child.argv = argv;
child.out = -1;
if (start_command(&child) != 0 ||