diff options
author | Ramkumar Ramachandra <artagnon@gmail.com> | 2013-05-31 17:42:14 +0530 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-06-03 10:50:22 -0700 |
commit | 276b22d333d4207928f6cfe3ab7c1898cd509b88 (patch) | |
tree | c12d0ce55ba84e39f6c52de8722cc132c608d38f /diffcore-pickaxe.c | |
parent | edca4152560522a431a51fc0a06147fc680b5b18 (diff) | |
download | git-276b22d333d4207928f6cfe3ab7c1898cd509b88.tar.gz |
diffcore-pickaxe: make error messages more consistent
Currently, diffcore-pickaxe reports two distinct errors for the same
user error:
$ git log --pickaxe-regex -S'\1'
fatal: invalid pickaxe regex: Invalid back reference
$ git log -G'\1'
fatal: invalid log-grep regex: Invalid back reference
This "log-grep" was only an internal name for the -G feature during
development, and invite confusion with "git log --grep=<pattern>".
Change the error messages to say "invalid regex".
Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diffcore-pickaxe.c')
-rw-r--r-- | diffcore-pickaxe.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/diffcore-pickaxe.c b/diffcore-pickaxe.c index 63722f86dc..c97ac9b463 100644 --- a/diffcore-pickaxe.c +++ b/diffcore-pickaxe.c @@ -122,7 +122,7 @@ static void diffcore_pickaxe_grep(struct diff_options *o) char errbuf[1024]; regerror(err, ®ex, errbuf, 1024); regfree(®ex); - die("invalid log-grep regex: %s", errbuf); + die("invalid regex: %s", errbuf); } pickaxe(&diff_queued_diff, o, ®ex, NULL, diff_grep); @@ -246,7 +246,7 @@ static void diffcore_pickaxe_count(struct diff_options *o) char errbuf[1024]; regerror(err, ®ex, errbuf, 1024); regfree(®ex); - die("invalid pickaxe regex: %s", errbuf); + die("invalid regex: %s", errbuf); } regexp = ®ex; } else { |