aboutsummaryrefslogtreecommitdiff
path: root/builtin-blame.c
diff options
context:
space:
mode:
authorRobin Rosenberg <robin.rosenberg.lists@dewire.com>2008-02-01 05:07:04 +0100
committerJunio C Hamano <gitster@pobox.com>2008-02-05 00:44:10 -0800
commit097971f5f564dbd832eea774ae0cdcfa03ba35ac (patch)
treea914d9e6c8f1f632db4eb973d254376c9ef86546 /builtin-blame.c
parentd089ebaad5315325d67db30176df1bbd7754fda9 (diff)
downloadgit-097971f5f564dbd832eea774ae0cdcfa03ba35ac.tar.gz
git-097971f5f564dbd832eea774ae0cdcfa03ba35ac.tar.xz
Make blame accept absolute paths
Blame did not always use prefix_path. Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-blame.c')
-rw-r--r--builtin-blame.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/builtin-blame.c b/builtin-blame.c
index 9b4c02e87..dea640d17 100644
--- a/builtin-blame.c
+++ b/builtin-blame.c
@@ -1894,9 +1894,7 @@ static unsigned parse_score(const char *arg)
static const char *add_prefix(const char *prefix, const char *path)
{
- if (!prefix || !prefix[0])
- return path;
- return prefix_path(prefix, strlen(prefix), path);
+ return prefix_path(prefix, prefix ? strlen(prefix) : 0, path);
}
/*