X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/b4a09b72ee15757c8ae41039e9bef6c5c309b6a8..0888952768eeaa90ba826565631847003d75b9b4:/flist.c diff --git a/flist.c b/flist.c index 6bbf3224..979090e7 100644 --- a/flist.c +++ b/flist.c @@ -1185,6 +1185,8 @@ struct file_list *send_file_list(int f, int argc, char *argv[]) } else break; } + if (len == 1 && fn[0] == '/') + fn[len++] = '.'; fn[len] = '\0'; /* Reject a ".." dir in the active part of the path. */ for (p = fn; (p = strstr(p, "..")) != NULL; p += 2) {