aboutsummaryrefslogtreecommitdiffstats
path: root/io.c
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2009-12-15 08:32:18 -0800
committerWayne Davison <wayned@samba.org>2009-12-15 08:32:18 -0800
commitc5130bc123aa5ddf7b10528a36fefbab1669084b (patch)
tree6616b4836bde057bae71fda72edaf2a68ea09b6b /io.c
parentf8e1fa627219873be6d37244dc70fbfd157f1e9c (diff)
downloadandroid_external_rsync-c5130bc123aa5ddf7b10528a36fefbab1669084b.tar.gz
android_external_rsync-c5130bc123aa5ddf7b10528a36fefbab1669084b.tar.bz2
android_external_rsync-c5130bc123aa5ddf7b10528a36fefbab1669084b.zip
Improve the timeout messages.
Diffstat (limited to 'io.c')
-rw-r--r--io.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/io.c b/io.c
index d142a1a6..c22b65f5 100644
--- a/io.c
+++ b/io.c
@@ -38,7 +38,6 @@ extern int bwlimit;
extern size_t bwlimit_writemax;
extern int io_timeout;
extern int am_server;
-extern int am_daemon;
extern int am_sender;
extern int am_generator;
extern int msgs2stderr;
@@ -168,10 +167,10 @@ static void check_timeout(void)
t = time(NULL);
if (t - last_io_in >= io_timeout) {
- if (!am_server && !am_daemon) {
- rprintf(FERROR, "io timeout after %d seconds -- exiting\n",
- (int)(t-last_io_in));
- }
+ if (am_server)
+ msgs2stderr = 1;
+ rprintf(FERROR, "[%s] io timeout after %d seconds -- exiting\n",
+ who_am_i(), (int)(t-last_io_in));
exit_cleanup(RERR_TIMEOUT);
}
}