On Sat, Jun 11, 2005 at 02:05:48PM -0400, Erik Jan Tromp wrote:
> #0  0x08060566 in flist_find ()
> #1  0x0804c6cd in recv_generator ()

OK, the crash turned out to be caused by an empty file-list not getting
its "high" value set correctly.  If such an empty list gets passed to
flist_find(), it would crash.  This is not something that normally
happens, but in the case where an empty destination directory is matched
up with a list-dest directory that has a file that is present but not
up-to-date, rsync triggers the bug.  Attached is a patch to fix this.

Thanks for your help!

..wayne..
--- flist.c     27 May 2005 18:15:18 -0000      1.297
+++ flist.c     12 Jun 2005 06:04:10 -0000
@@ -1471,8 +1471,12 @@ static void clean_flist(struct file_list
 {
        int i, prev_i = 0;
 
-       if (!flist || flist->count == 0)
+       if (!flist)
                return;
+       if (flist->count == 0) {
+               flist->high = -1;
+               return;
+       }
 
        sorting_flist = flist;
        qsort(flist->files, flist->count,
-- 
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html

Reply via email to