-+ set_file_attrs(fname, file, stp, 0);
- if (preserve_hard_links && file->link_u.links) {
- if (dry_run)
- file->link_u.links->link_dest_used = j + 1;
-@@ -1040,7 +1047,7 @@ static void recv_generator(char *fname,
- rsyserr(FERROR, errno,
- "recv_generator: mkdir %s failed",
- full_fname(fname));
-- file->flags |= FLAG_MISSING;
-+ FFLAGS(file) |= FLAG_MISSING;
- if (ndx+1 < the_file_list->count
- && the_file_list->files[ndx+1]->dir.depth > file->dir.depth) {
- rprintf(FERROR,
-@@ -1056,7 +1063,7 @@ static void recv_generator(char *fname,
- if (real_ret != 0 && one_file_system)
- real_st.st_dev = filesystem_dev;
- if (delete_during && f_out != -1 && !phase && dry_run < 2
-- && (file->flags & FLAG_DEL_HERE))
-+ && (FFLAGS(file) & FLAG_DEL_HERE))
- delete_in_dir(the_file_list, fname, file, &real_st);
- return;
- }
-@@ -1360,7 +1367,7 @@ static void recv_generator(char *fname,
- if (fuzzy_dirlist) {
- int j = flist_find(fuzzy_dirlist, file);
- if (j >= 0) /* don't use changing file as future fuzzy basis */
-- fuzzy_dirlist->files[j]->flags |= FLAG_NO_FUZZY;
-+ FFLAGS(fuzzy_dirlist->files[j]) |= FLAG_NO_FUZZY;
- }
-
- /* open the file */
-@@ -1625,7 +1632,7 @@ void generate_files(int f_out, struct fi
- continue;
- if (!need_retouch_dir_times && file->mode & S_IWUSR)
- continue;
-- if (file->flags & FLAG_MISSING) {
-+ if (FFLAGS(file) & FLAG_MISSING) {
- int missing = file->dir.depth;
- while (++i < flist->count) {
- file = flist->files[i];
---- old/hlink.c
-+++ new/hlink.c
-@@ -30,6 +30,7 @@ extern int make_backups;
- extern int remove_source_files;
- extern int stdout_format_has_i;
- extern char *basis_dir[];
-+extern unsigned int file_struct_len;
- extern struct file_list *the_file_list;
-
- #ifdef SUPPORT_HARD_LINKS
-@@ -91,10 +92,10 @@ static void link_idev_data(void)
- FPTR(cur)->link_u.links = pool_talloc(hlink_pool,
- struct hlink, 1, "hlink_list");
-
-- FPTR(head)->flags |= FLAG_HLINK_TOL;
-+ FFLAGS(FPTR(head)) |= FLAG_HLINK_TOL;
- FPTR(cur)->F_HLINDEX = to;
- FPTR(cur)->F_NEXT = head;
-- FPTR(cur)->flags |= FLAG_HLINK_EOL;
-+ FFLAGS(FPTR(cur)) |= FLAG_HLINK_EOL;
- FPTR(cur)->link_u.links->link_dest_used = 0;
- hlink_list[to++] = head;
- } else
-@@ -181,7 +182,7 @@ int hard_link_check(struct file_struct *
- {
- #ifdef SUPPORT_HARD_LINKS
- int head;
-- if (skip && !(file->flags & FLAG_HLINK_EOL))
-+ if (skip && !(FFLAGS(file) & FLAG_HLINK_EOL))
- head = hlink_list[file->F_HLINDEX] = file->F_NEXT;
- else
- head = hlink_list[file->F_HLINDEX];
-@@ -289,8 +290,8 @@ void hard_link_cluster(struct file_struc
- file->F_HLINDEX = FINISHED_LINK;
- if (link_stat(f_name(file, hlink1), &st1, 0) < 0)
- return;
-- if (!(file->flags & FLAG_HLINK_TOL)) {
-- while (!(file->flags & FLAG_HLINK_EOL)) {
-+ if (!(FFLAGS(file) & FLAG_HLINK_TOL)) {
-+ while (!(FFLAGS(file) & FLAG_HLINK_EOL)) {
- ndx = file->F_NEXT;
- file = FPTR(ndx);
- }
-@@ -310,6 +311,6 @@ void hard_link_cluster(struct file_struc
- send_msg(MSG_SUCCESS, numbuf, 4);
- }
- file->F_HLINDEX = FINISHED_LINK;
-- } while (!(file->flags & FLAG_HLINK_EOL));
-+ } while (!(FFLAGS(file) & FLAG_HLINK_EOL));
- #endif
- }
++ set_file_attrs(fname, file, sxp, 0);
+ if (preserve_hard_links && F_IS_HLINKED(file))
+ finish_hard_link(file, fname, &sxp->st, itemizing, code, j);
+ if (itemizing && (verbose > 1 || stdout_format_has_i > 1)) {
+@@ -1741,7 +1747,7 @@ static void touch_up_dirs(struct file_li
+ if (!(file->mode & S_IWUSR))
+ do_chmod(fname, file->mode);
+ if (need_retouch_dir_times)
+- set_modtime(fname, file->modtime, file->mode);
++ set_times(fname, file->modtime, file->modtime, file->mode);
+ if (allowed_lull && !(++j % lull_mod))
+ maybe_send_keepalive();
+ else if (!(j % 200))