patch is for rsync cvs sources after appling acls.diff and xattrs.diff patches. Please comment or include it upstream.
PS: please cc me, I'm not on list ---------------------------------------------------- Producenci "Opowieści z Narnii" przedstawiają: Wielka przygoda w świecie, w którym wszystko jest możliwe! MOST DO TERABITHII - w kinach od 9 marca! http://klik.wp.pl/?adr=http%3A%2F%2Fadv.reklama.wp.pl%2Fas%2Fmost.html&sid=1044
--- rsync-orig/xattr.c 2007-03-06 11:34:04.000000000 +0100 +++ rsync/xattr.c 2007-03-06 11:34:30.000000000 +0100 @@ -374,12 +374,44 @@ void cache_xattr(struct file_struct *fil F_XATTR(file) = ndx; } +static int rsync_xal_clear(const char *fname) +{ + item_list *xalp; + size_t i; + int ret; + + xalp = new(item_list); + *xalp = empty_xattr; + + ret = rsync_xal_get(fname, xalp); + if (ret == 0) { + rsync_xa *rxas = xalp->items; + + for (i = 0; i < xalp->count; i++) { + int status = sys_lremovexattr(fname, rxas[i].name); + if (status < 0) { + rsyserr(FERROR, errno, + "rsync_xal_clear: lremovexattr(\"%s\",\"%s\") failed", + fname, rxas[i].name); + ret = -1; + + } + } + } + + rsync_xal_free(xalp); + free(xalp); + return ret; +} + static int rsync_xal_set(const char *fname, item_list *xalp) { rsync_xa *rxas = xalp->items; size_t i; int ret = 0; + ret = rsync_xal_clear(fname); + for (i = 0; i < xalp->count; i++) { int status = sys_lsetxattr(fname, rxas[i].name, rxas[i].datum, rxas[i].datum_len); if (status < 0) {
-- To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html