- strcpy(object_hex, sha1_to_hex(object));
- printf("tagged %.*s %s (%.*s) in %s\n",
- typelen, type_line + 5,
- object_hex,
- taglen, tag_line + 4,
- sha1_to_hex(sha1));
- return 0;
-}
-
-static int fsck_entry(unsigned char *sha1, char *tag, void *data,
- unsigned long size)
-{
- if (!strcmp(tag, "blob")) {
- if (fsck_blob(sha1, data, size) < 0)
- return -1;
- } else if (!strcmp(tag, "tree")) {
- if (fsck_tree(sha1, data, size) < 0)
- return -1;
- } else if (!strcmp(tag, "commit")) {
- if (fsck_commit(sha1, data, size) < 0)
- return -1;
- } else if (!strcmp(tag, "tag")) {
- if (fsck_tag(sha1, data, size) < 0)
- return -1;
- } else
- return -1;
+ printf("tagged %s %s",
+ tag->tagged->type,
+ sha1_to_hex(tag->tagged->sha1));
+ printf(" (%s) in %s\n",
+ tag->tag, sha1_to_hex(tag->object.sha1));