#define XMIT_USER_OBJ (1<<0)
#define XMIT_USER_LIST (1<<1)
#define XMIT_GROUP_OBJ (1<<2)
#define XMIT_USER_OBJ (1<<0)
#define XMIT_USER_LIST (1<<1)
#define XMIT_GROUP_OBJ (1<<2)
for (ida = idal->idas; count--; ida++) {
char *name = user_names ? add_uid(ida->id) : add_gid(ida->id);
for (ida = idal->idas; count--; ida++) {
char *name = user_names ? add_uid(ida->id) : add_gid(ida->id);
if (inc_recurse && name) {
int len = strlen(name);
write_byte(f, ida->access | (uchar)0x80);
if (inc_recurse && name) {
int len = strlen(name);
write_byte(f, ida->access | (uchar)0x80);
int ndx = find_matching_rsync_acl(racl, type, racl_list);
/* Send 0 (-1 + 1) to indicate that literal ACL data follows. */
int ndx = find_matching_rsync_acl(racl, type, racl_list);
/* Send 0 (-1 + 1) to indicate that literal ACL data follows. */
static uchar recv_ida_entries(ida_entries *ent, int user_names, int f)
{
uchar computed_mask_bits = 0;
static uchar recv_ida_entries(ida_entries *ent, int user_names, int f)
{
uchar computed_mask_bits = 0;
int access = recv_acl_access(&has_name, f);
if (has_name) {
if (user_names)
id = recv_user_name(f, id);
else
int access = recv_acl_access(&has_name, f);
if (has_name) {
if (user_names)
id = recv_user_name(f, id);
else
if (ndx < 0 || (size_t)ndx > racl_list->count) {
rprintf(FERROR, "recv_acl_index: %s ACL index %d > %d\n",
if (ndx < 0 || (size_t)ndx > racl_list->count) {
rprintf(FERROR, "recv_acl_index: %s ACL index %d > %d\n",
-/* Non-incremental recursion needs to convert all the received IDs
- * in a single pass after the file-list is complete. */
+/* Non-incremental recursion needs to convert all the received IDs.
+ * This is done in a single pass after receiving the whole file-list. */
static void match_racl_ids(const item_list *racl_list)
{
int list_cnt, name_cnt;
acl_duo *duo_item = racl_list->items;
for (list_cnt = racl_list->count; list_cnt--; duo_item++) {
ida_entries *idal = &duo_item->racl.users;
static void match_racl_ids(const item_list *racl_list)
{
int list_cnt, name_cnt;
acl_duo *duo_item = racl_list->items;
for (list_cnt = racl_list->count; list_cnt--; duo_item++) {
ida_entries *idal = &duo_item->racl.users;
- for (name_cnt = idal->count; name_cnt--; idal++) {
- id_access *ida = idal->idas;
- ida->id = match_gid(ida->id);
- }
+ ida = idal->idas;
+ for (name_cnt = idal->count; name_cnt--; ida++)
+ ida->id = match_gid(ida->id, NULL);