Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e3bc529
)
Add a colon if a non-empty pre-xfer exec message follows.
author
Wayne Davison
<wayned@samba.org>
Sat, 4 Jun 2011 19:12:25 +0000
(12:12 -0700)
committer
Wayne Davison
<wayned@samba.org>
Sat, 4 Jun 2011 19:12:49 +0000
(12:12 -0700)
clientserver.c
patch
|
blob
|
blame
|
history
diff --git
a/clientserver.c
b/clientserver.c
index
91612ea
..
fbd3af6
100644
(file)
--- a/
clientserver.c
+++ b/
clientserver.c
@@
-396,9
+396,10
@@
static char *finish_pre_exec(pid_t pid, int write_fd, int read_fd, char *request
if (wait_process(pid, &status, 0) < 0
|| !WIFEXITED(status) || WEXITSTATUS(status) != 0) {
char *e;
if (wait_process(pid, &status, 0) < 0
|| !WIFEXITED(status) || WEXITSTATUS(status) != 0) {
char *e;
- if (asprintf(&e, "pre-xfer exec returned failure (%d)%s%s\n%s",
+ if (asprintf(&e, "pre-xfer exec returned failure (%d)%s%s
%s
\n%s",
status, status < 0 ? ": " : "",
status, status < 0 ? ": " : "",
- status < 0 ? strerror(errno) : "", buf) < 0)
+ status < 0 ? strerror(errno) : "",
+ *buf ? ":" : "", buf) < 0)
return "out_of_memory in finish_pre_exec\n";
return e;
}
return "out_of_memory in finish_pre_exec\n";
return e;
}