The code can now set cur_flist to NULL sooner than it used to, so the
authorWayne Davison <wayned@samba.org>
Tue, 30 Jan 2007 03:57:55 +0000 (03:57 +0000)
committerWayne Davison <wayned@samba.org>
Tue, 30 Jan 2007 03:57:55 +0000 (03:57 +0000)
flist_for_ndx() routine needs to work when cur_flist is NULL.

rsync.c

diff --git a/rsync.c b/rsync.c
index 0a38353..cba5441 100644 (file)
--- a/rsync.c
+++ b/rsync.c
@@ -407,7 +407,7 @@ struct file_list *flist_for_ndx(int ndx)
 {
        struct file_list *flist = cur_flist;
 
-       if (!flist)
+       if (!flist && !(flist = first_flist))
                return NULL;
 
        while (ndx < flist->ndx_start) {