A bit more fixing, as requested by Matt.
authorWayne Davison <wayned@samba.org>
Wed, 14 Mar 2007 20:36:06 +0000 (20:36 +0000)
committerWayne Davison <wayned@samba.org>
Wed, 14 Mar 2007 20:36:06 +0000 (20:36 +0000)
ignore-case.diff

index 416afee49f16a4861b47434afd7a592234502677..02b00ee7e840591b2544e9543b34f360f34713de 100644 (file)
@@ -136,9 +136,35 @@ To use this patch, run these commands for a successful build:
  }
  
  /* Match the "pattern" against the forced-to-lower-case "text" string. */
+@@ -331,12 +348,14 @@ int wildmatch_array(const char *pattern,
+     if (!text)
+       return FALSE;
++    force_lower_case = ignore_case;
++
+     if ((matched = dowild(p, text, a)) != TRUE && where < 0
+      && matched != ABORT_ALL) {
+       while (1) {
+           if (*text == '\0') {
+               if ((text = (uchar*)*a++) == NULL)
+-                  return FALSE;
++                  break;
+               continue;
+           }
+           if (*text++ == '/' && (matched = dowild(p, text, a)) != FALSE
+@@ -344,6 +363,9 @@ int wildmatch_array(const char *pattern,
+               break;
+       }
+     }
++
++    force_lower_case = 0;
++
+     return matched == TRUE;
+ }
 --- old/options.c
 +++ new/options.c
-@@ -111,6 +111,7 @@ OFF_T max_size = 0;
+@@ -112,6 +112,7 @@ OFF_T max_size = 0;
  OFF_T min_size = 0;
  int ignore_errors = 0;
  int modify_window = 0;
@@ -146,7 +172,7 @@ To use this patch, run these commands for a successful build:
  int blocking_io = -1;
  int checksum_seed = 0;
  int inplace = 0;
-@@ -366,6 +367,7 @@ void usage(enum logcode F)
+@@ -367,6 +368,7 @@ void usage(enum logcode F)
    rprintf(F,"     --include-from=FILE     read include patterns from FILE\n");
    rprintf(F,"     --files-from=FILE       read list of source-file names from FILE\n");
    rprintf(F," -0, --from0                 all *-from/filter files are delimited by 0s\n");
@@ -154,7 +180,7 @@ To use this patch, run these commands for a successful build:
    rprintf(F,"     --address=ADDRESS       bind address for outgoing socket to daemon\n");
    rprintf(F,"     --port=PORT             specify double-colon alternate port number\n");
    rprintf(F,"     --sockopts=OPTIONS      specify custom TCP options\n");
-@@ -534,6 +536,7 @@ static struct poptOption long_options[] 
+@@ -539,6 +541,7 @@ static struct poptOption long_options[] 
    {"only-write-batch", 0,  POPT_ARG_STRING, &batch_name, OPT_ONLY_WRITE_BATCH, 0, 0 },
    {"files-from",       0,  POPT_ARG_STRING, &files_from, 0, 0, 0 },
    {"from0",           '0', POPT_ARG_NONE,   &eol_nulls, 0, 0, 0},
@@ -162,7 +188,7 @@ To use this patch, run these commands for a successful build:
    {"numeric-ids",      0,  POPT_ARG_NONE,   &numeric_ids, 0, 0, 0 },
    {"timeout",          0,  POPT_ARG_INT,    &io_timeout, 0, 0, 0 },
    {"rsh",             'e', POPT_ARG_STRING, &shell_cmd, 0, 0, 0 },
-@@ -1733,6 +1736,9 @@ void server_options(char **args,int *arg
+@@ -1738,6 +1741,9 @@ void server_options(char **args,int *arg
                args[ac++] = arg;
        }