=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/rsync/sender.c,v retrieving revision 1.29 retrieving revision 1.30 diff -c -r1.29 -r1.30 *** src/usr.bin/rsync/sender.c 2021/06/30 13:10:04 1.29 --- src/usr.bin/rsync/sender.c 2021/08/29 13:43:46 1.30 *************** *** 1,4 **** ! /* $OpenBSD: sender.c,v 1.29 2021/06/30 13:10:04 claudio Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * --- 1,4 ---- ! /* $OpenBSD: sender.c,v 1.30 2021/08/29 13:43:46 claudio Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * *************** *** 358,364 **** { struct flist *fl = NULL; const struct flist *f; ! size_t i, flsz = 0, phase = 0, excl; int rc = 0, c; int32_t idx; struct pollfd pfd[3]; --- 358,364 ---- { struct flist *fl = NULL; const struct flist *f; ! size_t i, flsz = 0, phase = 0; int rc = 0, c; int32_t idx; struct pollfd pfd[3]; *************** *** 393,405 **** } /* Client sends zero-length exclusions if deleting. */ - if (!sess->opts->server && sess->opts->del && - !io_write_int(sess, fdout, 0)) { - ERRX1("io_write_int"); - goto out; - } - /* * Then the file list in any mode. * Finally, the IO error (always zero for us). --- 393,401 ---- } /* Client sends zero-length exclusions if deleting. */ + if (!sess->opts->server && sess->opts->del) + send_rules(sess, fdout); /* * Then the file list in any mode. * Finally, the IO error (always zero for us). *************** *** 427,441 **** * This is always 0 for now. */ ! if (sess->opts->server) { ! if (!io_read_size(sess, fdin, &excl)) { ! ERRX1("io_read_size"); ! goto out; ! } else if (excl != 0) { ! ERRX1("exclusion list is non-empty"); ! goto out; ! } ! } /* * Set up our poll events. --- 423,430 ---- * This is always 0 for now. */ ! if (sess->opts->server) ! recv_rules(sess, fdin); /* * Set up our poll events.