Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
4ade505
)
- Use F_OWNER() and F_GROUP() instead of F_UID() and F_GID().
author
Wayne Davison
<wayned@samba.org>
Sun, 20 May 2007 07:10:45 +0000
(07:10 +0000)
committer
Wayne Davison
<wayned@samba.org>
Sun, 20 May 2007 07:10:45 +0000
(07:10 +0000)
xattrs.c
patch
|
blob
|
blame
|
history
diff --git
a/xattrs.c
b/xattrs.c
index
f662cf7
..
7591660
100644
(file)
--- 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_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,
/* 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
}
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),
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;
if (sys_lsetxattr(fname, XSTAT_ATTR, buf, len) < 0) {
if (errno == EPERM && S_ISLNK(fst.st_mode))
return 0;