diff: migrate diff_flags.pickaxe_ignore_case to a pickaxe_opts bit
[gitweb.git] / diffcore-pickaxe.c
index 9476bd21081f456be6ae6412ea591e11dde50686..4b5d88ea4648ceb9efd461b40ef1838f1bc44c73 100644 (file)
@@ -222,11 +222,11 @@ void diffcore_pickaxe(struct diff_options *o)
 
        if (opts & (DIFF_PICKAXE_REGEX | DIFF_PICKAXE_KIND_G)) {
                int cflags = REG_EXTENDED | REG_NEWLINE;
-               if (o->flags.pickaxe_ignore_case)
+               if (o->pickaxe_opts & DIFF_PICKAXE_IGNORE_CASE)
                        cflags |= REG_ICASE;
                regcomp_or_die(&regex, needle, cflags);
                regexp = &regex;
-       } else if (o->flags.pickaxe_ignore_case &&
+       } else if (o->pickaxe_opts & DIFF_PICKAXE_IGNORE_CASE &&
                   has_non_ascii(needle)) {
                struct strbuf sb = STRBUF_INIT;
                int cflags = REG_NEWLINE | REG_ICASE;
@@ -236,7 +236,7 @@ void diffcore_pickaxe(struct diff_options *o)
                strbuf_release(&sb);
                regexp = &regex;
        } else {
-               kws = kwsalloc(o->flags.pickaxe_ignore_case
+               kws = kwsalloc(o->pickaxe_opts & DIFF_PICKAXE_IGNORE_CASE
                               ? tolower_trans_tbl : NULL);
                kwsincr(kws, needle, strlen(needle));
                kwsprep(kws);