return 0;
for (i = 0; i < merge_rr.nr; i++) {
const char *path = merge_rr.items[i].string;
- const char *name = (const char *)merge_rr.items[i].util;
- if (diff_two(rerere_path(name, "preimage"), path, path, path))
- die("unable to generate diff for %s", name);
+ const struct rerere_id *id = merge_rr.items[i].util;
- diff_two(rerere_path(id, "preimage"), path, path, path);
++ if (diff_two(rerere_path(id, "preimage"), path, path, path))
++ die("unable to generate diff for %s", rerere_path(id, NULL));
}
} else
usage_with_options(rerere_usage, options);
conn->in = conn->out = -1;
if (protocol == PROTO_SSH) {
const char *ssh;
- int putty, tortoiseplink = 0;
+ int putty = 0, tortoiseplink = 0;
char *ssh_host = hostandport;
const char *port = NULL;
+ transport_check_allowed("ssh");
get_host_and_port(&ssh_host, &port);
if (!port)
argv_array_push(&conn->args, port);
}
argv_array_push(&conn->args, ssh_host);
- /* remove repo-local variables from the environment */
- conn->env = local_repo_env;
- conn->use_shell = 1;
+ } else {
+ transport_check_allowed("file");
}
argv_array_push(&conn->args, cmd.buf);