summaryrefslogtreecommitdiff
path: root/rsync.c
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2007-11-25 13:49:41 -0800
committerWayne Davison <wayned@samba.org>2007-11-25 13:49:41 -0800
commit4d7c8e6b76b6a69cc044580f5759546a0570b65e (patch)
tree46d649d73a7c022dc3b442f3e8b3a3c74697718c /rsync.c
parenta685271de33c6d9d39fb1a8855fe214911c774e6 (diff)
downloadrsync-4d7c8e6b76b6a69cc044580f5759546a0570b65e.tar.gz
We now call set_stat_xattr() before set_xattr().
Diffstat (limited to 'rsync.c')
-rw-r--r--rsync.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/rsync.c b/rsync.c
index ca122561..47b0ca13 100644
--- a/rsync.c
+++ b/rsync.c
@@ -380,10 +380,10 @@ int set_file_attrs(const char *fname, struct file_struct *file, stat_x *sxp,
#endif
#ifdef SUPPORT_XATTRS
- if (preserve_xattrs && fnamecmp)
- set_xattr(fname, file, fnamecmp, sxp);
if (am_root < 0)
set_stat_xattr(fname, file, new_mode);
+ if (preserve_xattrs && fnamecmp)
+ set_xattr(fname, file, fnamecmp, sxp);
#endif
if (!preserve_times || (S_ISDIR(sxp->st.st_mode) && preserve_times == 1))