summaryrefslogtreecommitdiff
path: root/log-tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'log-tree.c')
-rw-r--r--log-tree.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/log-tree.c b/log-tree.c
index 74fc20da4d..c40fa50c6f 100644
--- a/log-tree.c
+++ b/log-tree.c
@@ -97,6 +97,8 @@ static int add_ref_decoration(const char *refname, const unsigned char *sha1, in
if (!prefixcmp(refname, "refs/replace/")) {
unsigned char original_sha1[20];
+ if (!read_replace_refs)
+ return 0;
if (get_sha1_hex(refname + 13, original_sha1)) {
warning("invalid replace ref %s", refname);
return 0;