- Added Matt's changes to lookup directory-default ACLs.
[rsync/rsync-patches.git] / cvs-entries.diff
index a6650df..61255e2 100644 (file)
@@ -2,9 +2,18 @@ This patch causes the --cvs-exclude option to prefix the names listed
 in each dir's CVS/Entries file as per-dir includes before the dir's list
 of excludes taken from the .cvsignore file.
 
---- orig/exclude.c     2005-10-14 18:45:50
-+++ exclude.c  2005-12-17 19:52:48
-@@ -446,6 +446,14 @@ void *push_local_filters(const char *dir
+--- orig/exclude.c     2005-12-24 07:53:38
++++ exclude.c  2005-12-17 21:18:38
+@@ -212,6 +212,8 @@ static void add_rule(struct filter_list_
+               if (!(lp = new_array(struct filter_list_struct, 1)))
+                       out_of_memory("add_rule");
+               lp->head = lp->tail = NULL;
++              if (mflags & MATCHFLG_CVS_IGNORE)
++                      cp = "CVS";
+               if (asprintf(&lp->debug_type, " [per-dir %s]", cp) < 0)
+                       out_of_memory("add_rule");
+               ret->u.mergelist = lp;
+@@ -446,6 +448,14 @@ void *push_local_filters(const char *dir
                                set_filter_dir(dir, dirlen);
                }
  
@@ -19,7 +28,7 @@ of excludes taken from the .cvsignore file.
                if (strlcpy(dirbuf + dirbuf_len, ex->pattern,
                    MAXPATHLEN - dirbuf_len) < MAXPATHLEN - dirbuf_len) {
                        parse_filter_file(lp, dirbuf, ex->match_flags,
-@@ -962,6 +970,7 @@ void parse_filter_file(struct filter_lis
+@@ -962,6 +972,7 @@ void parse_filter_file(struct filter_lis
        char line[BIGPATHBUFLEN];
        char *eob = line + sizeof line - 1;
        int word_split = mflags & MATCHFLG_WORD_SPLIT;
@@ -27,7 +36,7 @@ of excludes taken from the .cvsignore file.
  
        if (!fname || !*fname)
                return;
-@@ -1006,6 +1015,24 @@ void parse_filter_file(struct filter_lis
+@@ -1006,6 +1017,24 @@ void parse_filter_file(struct filter_lis
                                        continue;
                                break;
                        }
@@ -52,7 +61,7 @@ of excludes taken from the .cvsignore file.
                        if (word_split && isspace(ch))
                                break;
                        if (eol_nulls? !ch : (ch == '\n' || ch == '\r'))
-@@ -1015,13 +1042,15 @@ void parse_filter_file(struct filter_lis
+@@ -1015,13 +1044,15 @@ void parse_filter_file(struct filter_lis
                        else
                                overflow = 1;
                }
@@ -79,17 +88,17 @@ of excludes taken from the .cvsignore file.
  
  #define PERMS_REPORT          (1<<0)
  #define PERMS_SKIP_MTIME      (1<<1)
---- orig/testsuite/exclude.test        2005-02-26 19:47:43
-+++ testsuite/exclude.test     2005-12-17 19:52:49
-@@ -21,6 +21,7 @@ set -x
- # Build some files/dirs/links to copy
+--- orig/testsuite/exclude.test        2005-12-24 07:49:27
++++ testsuite/exclude.test     2005-12-30 07:32:41
+@@ -22,6 +22,7 @@ set -x
  
  makepath "$fromdir/foo/down/to/you"
+ makepath "$fromdir/foo/sub"
 +makepath "$fromdir/bar/down/to/CVS"
  makepath "$fromdir/bar/down/to/foo/too"
  makepath "$fromdir/bar/down/to/bar/baz"
  makepath "$fromdir/mid/for/foo/and/that/is/who"
-@@ -56,6 +57,9 @@ echo cvsout >"$fromdir/bar/down/to/foo/f
+@@ -58,6 +59,9 @@ echo cvsout >"$fromdir/bar/down/to/foo/f
  echo gone >"$fromdir/bar/down/to/foo/file3"
  echo lost >"$fromdir/bar/down/to/foo/file4"
  echo weird >"$fromdir/bar/down/to/foo/+ file3"
@@ -99,7 +108,7 @@ of excludes taken from the .cvsignore file.
  echo cvsout-but-filtin >"$fromdir/bar/down/to/foo/file4.junk"
  echo smashed >"$fromdir/bar/down/to/foo/to"
  cat >"$fromdir/bar/down/to/bar/.filt2" <<EOF
-@@ -98,7 +102,18 @@ cat >"$excl" <<EOF
+@@ -101,7 +105,18 @@ cat >"$excl" <<EOF
  EOF
  
  cat >"$scratchdir/.cvsignore" <<EOF
@@ -119,7 +128,7 @@ of excludes taken from the .cvsignore file.
  EOF
  
  # Create the chk dir with what we expect to be excluded
-@@ -125,6 +140,10 @@ checkit "$RSYNC -avv --exclude-from=\"$e
+@@ -128,6 +143,10 @@ checkit "$RSYNC -avv --exclude-from=\"$e
  # Modify the chk dir by removing cvs-ignored files and then tweaking the dir times.
  
  rm "$chkdir"/foo/*.old
@@ -130,7 +139,7 @@ of excludes taken from the .cvsignore file.
  rm "$chkdir"/bar/down/to/foo/*.bak
  rm "$chkdir"/bar/down/to/foo/*.junk
  rm "$chkdir"/bar/down/to/home-cvs-exclude
-@@ -140,8 +159,12 @@ checkit "$RSYNC -avvC --filter=\"merge $
+@@ -143,8 +162,12 @@ checkit "$RSYNC -avvC --filter=\"merge $
  
  # Modify the chk dir for our merge-exclude test and then tweak the dir times.