=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/rsync/uploader.c,v retrieving revision 1.6 retrieving revision 1.7 diff -c -r1.6 -r1.7 *** src/usr.bin/rsync/uploader.c 2019/02/14 18:31:01 1.6 --- src/usr.bin/rsync/uploader.c 2019/02/16 05:06:30 1.7 *************** *** 1,4 **** ! /* $Id: uploader.c,v 1.6 2019/02/14 18:31:01 florian Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * --- 1,4 ---- ! /* $Id: uploader.c,v 1.7 2019/02/16 05:06:30 deraadt Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * *************** *** 71,78 **** return; sz = strlen(f->path); assert(sz > 0); ! LOG1(sess, "%s%s", f->path, ! '/' == f->path[sz - 1] ? "" : "/"); } /* --- 71,77 ---- return; sz = strlen(f->path); assert(sz > 0); ! LOG1(sess, "%s%s", f->path, ('/' == f->path[sz - 1]) ? "" : "/"); } /* *************** *** 247,254 **** tv[0].tv_nsec = 0; tv[1].tv_sec = f->st.mtime; tv[1].tv_nsec = 0; ! rc = utimensat(p->rootfd, ! f->path, tv, AT_SYMLINK_NOFOLLOW); if (rc == -1) { ERR(sess, "%s: utimensat", f->path); return -1; --- 246,252 ---- tv[0].tv_nsec = 0; tv[1].tv_sec = f->st.mtime; tv[1].tv_nsec = 0; ! rc = utimensat(p->rootfd, f->path, tv, AT_SYMLINK_NOFOLLOW); if (rc == -1) { ERR(sess, "%s: utimensat", f->path); return -1; *************** *** 262,269 **** */ if (newlink || sess->opts->preserve_perms) { ! rc = fchmodat(p->rootfd, ! f->path, f->st.mode, AT_SYMLINK_NOFOLLOW); if (rc == -1) { ERR(sess, "%s: fchmodat", f->path); return -1; --- 260,266 ---- */ if (newlink || sess->opts->preserve_perms) { ! rc = fchmodat(p->rootfd, f->path, f->st.mode, AT_SYMLINK_NOFOLLOW); if (rc == -1) { ERR(sess, "%s: fchmodat", f->path); return -1; *************** *** 670,677 **** if (*fileinfd != -1 && st.st_size > 0) { mapsz = st.st_size; ! map = mmap(NULL, mapsz, ! PROT_READ, MAP_SHARED, *fileinfd, 0); if (map == MAP_FAILED) { WARN(sess, "%s: mmap", u->fl[u->idx].path); close(*fileinfd); --- 667,673 ---- if (*fileinfd != -1 && st.st_size > 0) { mapsz = st.st_size; ! map = mmap(NULL, mapsz, PROT_READ, MAP_SHARED, *fileinfd, 0); if (map == MAP_FAILED) { WARN(sess, "%s: mmap", u->fl[u->idx].path); close(*fileinfd);