summaryrefslogtreecommitdiff
path: root/tag.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <junkio@cox.net>2005-11-16 21:32:44 -0800
committerLibravatar Junio C Hamano <junkio@cox.net>2005-11-16 21:32:44 -0800
commit27dedf0c3b78d1072fb5449149421284f9e5297b (patch)
tree80da2302f50bb1f396611a4a54a6da52a4592bd0 /tag.c
parentGIT 0.99.9i aka 1.0rc2 (diff)
downloadtgif-27dedf0c3b78d1072fb5449149421284f9e5297b.tar.xz
GIT 0.99.9j aka 1.0rc3
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'tag.c')
-rw-r--r--tag.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/tag.c b/tag.c
index e574c4b7a4..61ac434d6b 100644
--- a/tag.c
+++ b/tag.c
@@ -75,8 +75,11 @@ int parse_tag_buffer(struct tag *item, void *data, unsigned long size)
item->tag[taglen] = '\0';
item->tagged = lookup_object_type(object, type);
- if (item->tagged)
- add_ref(&item->object, item->tagged);
+ if (item->tagged && track_object_refs) {
+ struct object_refs *refs = alloc_object_refs(1);
+ refs->ref[0] = item->tagged;
+ set_object_refs(&item->object, refs);
+ }
return 0;
}