summaryrefslogtreecommitdiff
path: root/xattrs.c
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2007-05-20 07:10:45 +0000
committerWayne Davison <wayned@samba.org>2007-05-20 07:10:45 +0000
commitfb7b9ddcb1165ad0ab9aba773e050816068d0b61 (patch)
treefb2d7c108c33fda54bb3688b7b57ada0099da61b /xattrs.c
parent4ade505c7ed255e2482b2a19bf40054c672d5b30 (diff)
downloadrsync-fb7b9ddcb1165ad0ab9aba773e050816068d0b61.tar.gz
- Use F_OWNER() and F_GROUP() instead of F_UID() and F_GID().
Diffstat (limited to 'xattrs.c')
-rw-r--r--xattrs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/xattrs.c b/xattrs.c
index f662cf7a..7591660e 100644
--- a/xattrs.c
+++ b/xattrs.c
@@ -886,7 +886,7 @@ int set_stat_xattr(const char *fname, struct file_struct *file)
fst.st_rdev = 0; /* just in case */
if (mode == fmode && fst.st_rdev == rdev
- && fst.st_uid == F_UID(file) && fst.st_gid == F_GID(file)) {
+ && fst.st_uid == F_OWNER(file) && fst.st_gid == F_GROUP(file)) {
/* xst.st_mode will be 0 if there's no current stat xattr */
if (xst.st_mode && sys_lremovexattr(fname, XSTAT_ATTR) < 0) {
rsyserr(FERROR, errno,
@@ -898,12 +898,12 @@ int set_stat_xattr(const char *fname, struct file_struct *file)
}
if (xst.st_mode != fmode || xst.st_rdev != rdev
- || xst.st_uid != F_UID(file) || xst.st_gid != F_GID(file)) {
+ || xst.st_uid != F_OWNER(file) || xst.st_gid != F_GROUP(file)) {
char buf[256];
int len = snprintf(buf, sizeof buf, "%o %u,%u %u:%u",
to_wire_mode(fmode),
(int)major(rdev), (int)minor(rdev),
- (int)F_UID(file), (int)F_GID(file));
+ F_OWNER(file), F_GROUP(file));
if (sys_lsetxattr(fname, XSTAT_ATTR, buf, len) < 0) {
if (errno == EPERM && S_ISLNK(fst.st_mode))
return 0;