Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-09-01 00:44:39 +0400
committerJunio C Hamano <gitster@pobox.com>2010-09-01 01:30:28 +0400
commit382f013bc40452e4c24b8698217a14ff35f6dcec (patch)
tree0a6241cc2c7cf54232f6999c40417fb6877666bc
parenta2c2cef0cd5210aa870e1d226d348a7ddd0277ff (diff)
diff: pass the entire diff-options to diffcore_pickaxe()
That would make it easier to give enhanced feature to the pickaxe transformation. Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--diff.c2
-rw-r--r--diffcore-pickaxe.c4
-rw-r--r--diffcore.h2
3 files changed, 5 insertions, 3 deletions
diff --git a/diff.c b/diff.c
index 6fb97d4623..6631fa387c 100644
--- a/diff.c
+++ b/diff.c
@@ -4166,7 +4166,7 @@ void diffcore_std(struct diff_options *options)
diffcore_merge_broken();
}
if (options->pickaxe)
- diffcore_pickaxe(options->pickaxe, options->pickaxe_opts);
+ diffcore_pickaxe(options);
if (options->orderfile)
diffcore_order(options->orderfile);
if (!options->found_follow)
diff --git a/diffcore-pickaxe.c b/diffcore-pickaxe.c
index 929de15aa9..13f61fbb08 100644
--- a/diffcore-pickaxe.c
+++ b/diffcore-pickaxe.c
@@ -48,8 +48,10 @@ static unsigned int contains(struct diff_filespec *one,
return cnt;
}
-void diffcore_pickaxe(const char *needle, int opts)
+void diffcore_pickaxe(struct diff_options *o)
{
+ const char *needle = o->pickaxe;
+ int opts = o->pickaxe_opts;
struct diff_queue_struct *q = &diff_queued_diff;
unsigned long len = strlen(needle);
int i, has_changes;
diff --git a/diffcore.h b/diffcore.h
index 8b3241ad13..b8f1fdecf4 100644
--- a/diffcore.h
+++ b/diffcore.h
@@ -107,7 +107,7 @@ extern void diff_q(struct diff_queue_struct *, struct diff_filepair *);
extern void diffcore_break(int);
extern void diffcore_rename(struct diff_options *);
extern void diffcore_merge_broken(void);
-extern void diffcore_pickaxe(const char *needle, int opts);
+extern void diffcore_pickaxe(struct diff_options *);
extern void diffcore_order(const char *orderfile);
#define DIFF_DEBUG 0