From a15c4b38b53152c498ef3b676fb629b43bd7060d Mon Sep 17 00:00:00 2001 From: Wayne Davison Date: Sun, 23 Sep 2007 16:02:33 +0000 Subject: [PATCH] Fix a glitch in the handling of the last path element in a -R path with a trailing slash. --- flist.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/flist.c b/flist.c index aef150d8..7f2778a1 100644 --- a/flist.c +++ b/flist.c @@ -1608,7 +1608,7 @@ static void send1extra(int f, struct file_struct *file, struct file_list *flist) if (is_dot_dir) { STRUCT_STAT st; - if (link_stat(fbuf, &st, copy_dirlinks) != 0) { + if (link_stat(fbuf, &st, 1) != 0) { io_error |= IOERR_GENERAL; rsyserr(FERROR, errno, "link_stat %s failed", full_fname(fbuf)); @@ -1905,7 +1905,7 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) if (fn != fbuf) memmove(fbuf, fn, len + 1); - if (link_stat(fbuf, &st, copy_dirlinks) != 0) { + if (link_stat(fbuf, &st, copy_dirlinks || is_dot_dir) != 0) { io_error |= IOERR_GENERAL; rsyserr(FERROR, errno, "link_stat %s failed", full_fname(fbuf)); -- 2.34.1