summaryrefslogtreecommitdiff
path: root/builtin/blame.c
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/blame.c')
-rw-r--r--builtin/blame.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/builtin/blame.c b/builtin/blame.c
index 5a0388a..468b17c 100644
--- a/builtin/blame.c
+++ b/builtin/blame.c
@@ -9,6 +9,7 @@
#include "config.h"
#include "color.h"
#include "builtin.h"
+#include "repository.h"
#include "commit.h"
#include "diff.h"
#include "revision.h"
@@ -23,6 +24,7 @@
#include "line-log.h"
#include "dir.h"
#include "progress.h"
+#include "object-store.h"
#include "blame.h"
#include "string-list.h"
@@ -576,7 +578,7 @@ static int read_ancestry(const char *graft_file)
/* The format is just "Commit Parent1 Parent2 ...\n" */
struct commit_graft *graft = read_graft_line(&buf);
if (graft)
- register_commit_graft(graft, 0);
+ register_commit_graft(the_repository, graft, 0);
}
fclose(fp);
strbuf_release(&buf);
@@ -1069,7 +1071,9 @@ parse_done:
find_alignment(&sb, &output_option);
if (!*repeated_meta_color &&
(output_option & OUTPUT_COLOR_LINE))
- strcpy(repeated_meta_color, GIT_COLOR_CYAN);
+ xsnprintf(repeated_meta_color,
+ sizeof(repeated_meta_color),
+ "%s", GIT_COLOR_CYAN);
}
if (output_option & OUTPUT_ANNOTATE_COMPAT)
output_option &= ~(OUTPUT_COLOR_LINE | OUTPUT_SHOW_AGE_WITH_COLOR);