Merge branch 'rs/child-process-init'

Code clean-up.

* rs/child-process-init:
  run-command: inline prepare_run_command_v_opt()
  run-command: call run_command_v_opt_cd_env() instead of duplicating it
  run-command: introduce child_process_init()
  run-command: introduce CHILD_PROCESS_INIT
This commit is contained in:
Junio C Hamano
2014-09-11 10:33:27 -07:00
41 changed files with 87 additions and 130 deletions

View File

@ -666,7 +666,7 @@ static int get_pack(struct fetch_pack_args *args,
char hdr_arg[256];
const char **av, *cmd_name;
int do_keep = args->keep_pack;
struct child_process cmd;
struct child_process cmd = CHILD_PROCESS_INIT;
int ret;
memset(&demux, 0, sizeof(demux));
@ -685,7 +685,6 @@ static int get_pack(struct fetch_pack_args *args,
else
demux.out = xd[0];
memset(&cmd, 0, sizeof(cmd));
cmd.argv = argv;
av = argv;
*hdr_arg = 0;