+- t = time(NULL);
+-
+ if (t - last_io_in >= io_timeout) {
+ if (!am_server && !am_daemon) {
+ rprintf(FERROR, "io timeout after %d seconds -- exiting\n",
+--- old/options.c
++++ new/options.c
+@@ -108,6 +108,7 @@ size_t bwlimit_writemax = 0;
+ int ignore_existing = 0;
+ int ignore_non_existing = 0;
+ int need_messages_from_generator = 0;
++time_t stop_at_utime = 0;
+ int max_delete = -1;
+ OFF_T max_size = 0;
+ OFF_T min_size = 0;
+@@ -390,6 +391,8 @@ void usage(enum logcode F)
+ rprintf(F," --password-file=FILE read daemon-access password from FILE\n");
+ rprintf(F," --list-only list the files instead of copying them\n");
+ rprintf(F," --bwlimit=KBPS limit I/O bandwidth; KBytes per second\n");
++ rprintf(F," --stop-at=y-m-dTh:m Stop rsync at year-month-dayThour:minute\n");
++ rprintf(F," --time-limit=MINS Stop rsync after MINS minutes have elapsed\n");
+ rprintf(F," --write-batch=FILE write a batched update to FILE\n");
+ rprintf(F," --only-write-batch=FILE like --write-batch but w/o updating destination\n");
+ rprintf(F," --read-batch=FILE read a batched update from FILE\n");
+@@ -411,7 +414,7 @@ enum {OPT_VERSION = 1000, OPT_DAEMON, OP
+ OPT_FILTER, OPT_COMPARE_DEST, OPT_COPY_DEST, OPT_LINK_DEST, OPT_HELP,
+ OPT_INCLUDE, OPT_INCLUDE_FROM, OPT_MODIFY_WINDOW, OPT_MIN_SIZE, OPT_CHMOD,
+ OPT_READ_BATCH, OPT_WRITE_BATCH, OPT_ONLY_WRITE_BATCH, OPT_MAX_SIZE,
+- OPT_NO_D,
++ OPT_NO_D, OPT_STOP_AT, OPT_TIME_LIMIT,
+ OPT_SERVER, OPT_REFUSED_BASE = 9000};