X-Git-Url: https://mattmccutchen.net/rsync/rsync-patches.git/blobdiff_plain/cc3e685d09b2095099fc396157d19172ab3ef7c4..4c15e80040f6ac2fc79d599d1722cf209cc30536:/usermap.diff diff --git a/usermap.diff b/usermap.diff index e40f981..2b89567 100644 --- a/usermap.diff +++ b/usermap.diff @@ -18,7 +18,7 @@ diff --git a/flist.c b/flist.c extern char curr_dir[MAXPATHLEN]; -@@ -753,7 +754,7 @@ static struct file_struct *recv_file_entry(struct file_list *flist, +@@ -752,7 +753,7 @@ static struct file_struct *recv_file_entry(struct file_list *flist, uid = (uid_t)read_varint(f); if (xflags & XMIT_USER_NAME_FOLLOWS) uid = recv_user_name(f, uid); @@ -27,7 +27,7 @@ diff --git a/flist.c b/flist.c uid = match_uid(uid); } } -@@ -765,7 +766,7 @@ static struct file_struct *recv_file_entry(struct file_list *flist, +@@ -764,7 +765,7 @@ static struct file_struct *recv_file_entry(struct file_list *flist, gid_flags = 0; if (xflags & XMIT_GROUP_NAME_FOLLOWS) gid = recv_group_name(f, gid, &gid_flags); @@ -36,7 +36,7 @@ diff --git a/flist.c b/flist.c gid = match_gid(gid, &gid_flags); } } -@@ -2090,8 +2091,13 @@ struct file_list *recv_file_list(int f) +@@ -2074,8 +2075,13 @@ struct file_list *recv_file_list(int f) int dstart, flags; int64 start_read; @@ -54,7 +54,7 @@ diff --git a/flist.c b/flist.c diff --git a/options.c b/options.c --- a/options.c +++ b/options.c -@@ -165,6 +165,8 @@ char *rsync_path = RSYNC_PATH; +@@ -166,6 +166,8 @@ char *rsync_path = RSYNC_PATH; char *backup_dir = NULL; char backup_dir_buf[MAXPATHLEN]; char *sockopts = NULL; @@ -63,7 +63,7 @@ diff --git a/options.c b/options.c int rsync_port = 0; int compare_dest = 0; int copy_dest = 0; -@@ -378,6 +380,8 @@ void usage(enum logcode F) +@@ -379,6 +381,8 @@ void usage(enum logcode F) rprintf(F," --delay-updates put all updated files into place at transfer's end\n"); rprintf(F," -m, --prune-empty-dirs prune empty directory chains from the file-list\n"); rprintf(F," --numeric-ids don't map uid/gid values by user/group name\n"); @@ -72,7 +72,7 @@ diff --git a/options.c b/options.c rprintf(F," --timeout=SECONDS set I/O timeout in seconds\n"); rprintf(F," --contimeout=SECONDS set daemon connection timeout in seconds\n"); rprintf(F," -I, --ignore-times don't skip files that match in size and mod-time\n"); -@@ -603,6 +607,8 @@ static struct poptOption long_options[] = { +@@ -604,6 +608,8 @@ static struct poptOption long_options[] = { {"no-s", 0, POPT_ARG_VAL, &protect_args, 0, 0, 0}, {"numeric-ids", 0, POPT_ARG_VAL, &numeric_ids, 1, 0, 0 }, {"no-numeric-ids", 0, POPT_ARG_VAL, &numeric_ids, 0, 0, 0 }, @@ -81,7 +81,7 @@ diff --git a/options.c b/options.c {"timeout", 0, POPT_ARG_INT, &io_timeout, 0, 0, 0 }, {"no-timeout", 0, POPT_ARG_VAL, &io_timeout, 0, 0, 0 }, {"contimeout", 0, POPT_ARG_INT, &connect_timeout, 0, 0, 0 }, -@@ -1934,6 +1940,18 @@ void server_options(char **args, int *argc_p) +@@ -1942,6 +1948,18 @@ void server_options(char **args, int *argc_p) args[ac++] = "--use-qsort"; if (am_sender) { @@ -188,7 +188,7 @@ diff --git a/uidlist.c b/uidlist.c + struct idlist { struct idlist *next; - char *name; + const char *name; @@ -48,8 +54,8 @@ struct idlist { uint16 flags; }; @@ -198,9 +198,9 @@ diff --git a/uidlist.c b/uidlist.c +static struct idlist *uidlist, *uidmap; +static struct idlist *gidlist, *gidmap; - static struct idlist *add_to_list(struct idlist **root, id_t id, char *name, + static struct idlist *add_to_list(struct idlist **root, id_t id, const char *name, id_t id2, uint16 flags) -@@ -84,22 +90,6 @@ static char *gid_to_name(gid_t gid) +@@ -84,22 +90,6 @@ static const char *gid_to_name(gid_t gid) return NULL; }