fsck: cleanup unused variable

Remove the unused variable "heads" from cmd_fsck(). This variable was made unused in commit c3271a0 ("fsck: do not fallback "git fsck <bogus>" to "git fsck"", 2017-01-17). Signed-off-by: Jonathan Tan <jonathantanmy@google.com> Reviewed-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jonathan Tan committed Jul 25, 2017 at 18:34 UTC 78e7b98f452dd8e6c4d88d28532a0a5e98885d59
1 file changed +1 -3
builtin/fsck.c
+1 -3
@@ -660,7 +660,7 @@ static struct option fsck_opts[] = {
660
661 int cmd_fsck(int argc, const char **argv, const char *prefix)
662 {
663 - int i, heads;
663 + int i;
664 struct alternate_object_database *alt;
665
666 errors_found = 0;
@@ -728,7 +728,6 @@ int cmd_fsck(int argc, const char **argv, const char *prefix)
728 }
729 }
730
731 - heads = 0;
731 for (i = 0; i < argc; i++) {
732 const char *arg = argv[i];
733 unsigned char sha1[20];
@@ -746,7 +745,6 @@ int cmd_fsck(int argc, const char **argv, const char *prefix)
745 add_decoration(fsck_walk_options.object_names,
746 obj, xstrdup(arg));
747 mark_object_reachable(obj);
749 - heads++;
748 continue;
749 }
750 error("invalid parameter: expected sha1, got '%s'", arg);