X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/3e607d23543f0f3fb7b72953b89334071540667f..de5fb3744da115dbdb66c7fbb894bf2ad9317fb7:/flist.c diff --git a/flist.c b/flist.c index e120f805..d3c07edc 100644 --- a/flist.c +++ b/flist.c @@ -262,6 +262,12 @@ static void receive_file_entry(struct file_struct **fptr, clean_fname(thisname); + if (relative_paths && thisname[0] == '/') { + /* strip / off absolute paths in destination */ + memmove(thisname, thisname+1, strlen(thisname)); + if (!thisname[0]) strcpy(thisname,"."); + } + if ((p = strrchr(thisname,'/'))) { static char *lastdir; *p = 0; @@ -403,10 +409,6 @@ static struct file_struct *make_file(char *fname) file->modtime = st.st_mtime; file->length = st.st_size; -#if TRIDGE - if (st.st_size == 71036) - file->length += 7000; -#endif file->mode = st.st_mode; file->uid = st.st_uid; file->gid = st.st_gid;