summaryrefslogtreecommitdiff
path: root/reflog-walk.c
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2007-01-20 02:28:19 (GMT)
committerJunio C Hamano <junkio@cox.net>2007-01-21 05:32:31 (GMT)
commitdb055e65d20b20f8f32eb85ee1a2417d3b95c1c7 (patch)
treeba5983bc5a58f05f011a6a5896d7a392d86ab67b /reflog-walk.c
parent8860fd42fcf5a7853f7d7c2198793183320293ff (diff)
downloadgit-db055e65d20b20f8f32eb85ee1a2417d3b95c1c7.zip
git-db055e65d20b20f8f32eb85ee1a2417d3b95c1c7.tar.gz
git-db055e65d20b20f8f32eb85ee1a2417d3b95c1c7.tar.bz2
--walk-reflogs: disallow uninteresting commits
Do not allow uninteresting commits with --walk-reflogs, since it is not clear what should be shown in these cases: $ git log --walk-reflogs master..next $ git log --walk-reflogs ^master Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Diffstat (limited to 'reflog-walk.c')
-rw-r--r--reflog-walk.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/reflog-walk.c b/reflog-walk.c
index d4b49c7..2d97411 100644
--- a/reflog-walk.c
+++ b/reflog-walk.c
@@ -145,6 +145,9 @@ void add_reflog_for_walk(struct reflog_walk_info *info,
char *branch, *at = strchr(name, '@');
struct commit_reflog *commit_reflog;
+ if (commit->object.flags & UNINTERESTING)
+ die ("Cannot walk reflogs for %s", name);
+
branch = xstrdup(name);
if (at && at[1] == '{') {
char *ep;