Commit 0b515981 authored by Wayne Davison's avatar Wayne Davison

Changed print_child_argv() to take its prefix message as an arg.

parent 2e8259bb
......@@ -242,7 +242,7 @@ int start_inband_exchange(int f_in, int f_out, const char *user, int argc, char
sargs[sargc] = NULL;
if (verbose > 1)
print_child_argv(sargs);
print_child_argv("sending daemon args:", sargs);
p = strchr(path, '/');
if (p) *p = '\0';
......
......@@ -50,7 +50,7 @@ pid_t piped_child(char **command, int *f_in, int *f_out)
int from_child_pipe[2];
if (verbose >= 2)
print_child_argv(command);
print_child_argv("opening connection using:", command);
if (fd_pair(to_child_pipe) < 0 || fd_pair(from_child_pipe) < 0) {
rsyserr(FERROR, errno, "pipe");
......
......@@ -90,9 +90,9 @@ int fd_pair(int fd[2])
return ret;
}
void print_child_argv(char **cmd)
void print_child_argv(const char *prefix, char **cmd)
{
rprintf(FCLIENT, "opening connection using ");
rprintf(FCLIENT, "%s ", prefix);
for (; *cmd; cmd++) {
/* Look for characters that ought to be quoted. This
* is not a great quoting algorithm, but it's
......@@ -1478,7 +1478,7 @@ void *expand_item_list(item_list *lp, size_t item_size,
void *new_ptr;
size_t new_size = lp->malloced;
if (incr < 0)
new_size -= incr; /* increase slowly */
new_size += -incr; /* increase slowly */
else if (new_size < (size_t)incr)
new_size += incr;
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment