X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/d17190df448e81e5192b6804f3c37bff75df82f7..8e6cf5d1891caeed1b1e6c446b8723cd33969b06:/sender.c diff --git a/sender.c b/sender.c index ca6ae1e3..b745f6f7 100644 --- a/sender.c +++ b/sender.c @@ -167,6 +167,13 @@ void send_files(struct file_list *flist, int f_out, int f_in) } if (i < 0 || i >= flist->count) { + /* Handle the new keep-alive (no-op) packet. */ + if (i == flist->count && protocol_version >= 29 + && read_shortint(f_in) == ITEM_IS_NEW) { + write_int(f_out, i); + write_shortint(f_out, ITEM_IS_NEW); + continue; + } rprintf(FERROR, "Invalid file index %d (count=%d)\n", i, flist->count); exit_cleanup(RERR_PROTOCOL);