summaryrefslogtreecommitdiff
path: root/log.c
diff options
context:
space:
mode:
Diffstat (limited to 'log.c')
-rw-r--r--log.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/log.c b/log.c
index ded8045b..58ad2736 100644
--- a/log.c
+++ b/log.c
@@ -870,10 +870,14 @@ void log_delete(const char *fname, int mode)
*/
void log_exit(int code, const char *file, int line)
{
- rprintf(FLOG,"sent %s bytes received %s bytes total size %s\n",
- big_num(stats.total_written),
- big_num(stats.total_read),
- big_num(stats.total_size));
+ /* The receiving side's stats are split between 2 procs until the
+ * end of the run, so only the sender can output non-final info. */
+ if (code == 0 || am_sender) {
+ rprintf(FLOG,"sent %s bytes received %s bytes total size %s\n",
+ big_num(stats.total_written),
+ big_num(stats.total_read),
+ big_num(stats.total_size));
+ }
if (code != 0 && am_server != 2) {
const char *name;