git-compat-util.h: move SHELL_PATH default into header
If SHELL_PATH is not defined we use "/bin/sh". However, run-command.c is not the only file that needs to use the default value so move it into a common header. Signed-off-by: Kyle J. McKay <mackyle@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Kyle J. McKay committed
Mar 7, 2015 at 21:07 UTC
1b56cdf901f6e6a73d0edadf56afb1c878c7622a
2 files changed
+4
-4
git-compat-util.h
+4
@@ -872,4 +872,8 @@ struct tm *git_gmtime_r(const time_t *, struct tm *);
872
#define gmtime_r git_gmtime_r
873
#endif
874
875
+#ifndef SHELL_PATH
876
+# define SHELL_PATH "/bin/sh"
877
+#endif
878
+
879
#endif
run-command.c
-4
@@ -4,10 +4,6 @@
4
#include "sigchain.h"
5
#include "argv-array.h"
6
7
-#ifndef SHELL_PATH
8
-# define SHELL_PATH "/bin/sh"
9
-#endif
10
-
7
void child_process_init(struct child_process *child)
8
{
9
memset(child, 0, sizeof(*child));