From 9da187e83d1b8ab513a43fd54a9fe2be11b1703f Mon Sep 17 00:00:00 2001 From: Russell Belfer Date: Tue, 9 Apr 2013 11:40:00 -0700 Subject: Fix clang warnings and improve checks --- examples/network/index-pack.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'examples/network/index-pack.c') diff --git a/examples/network/index-pack.c b/examples/network/index-pack.c index 3fc4f3288..889305da8 100644 --- a/examples/network/index-pack.c +++ b/examples/network/index-pack.c @@ -23,7 +23,7 @@ // the indexing to finish in a worker thread static int index_cb(const git_transfer_progress *stats, void *data) { - data = data; + (void)data; printf("\rProcessing %d of %d", stats->indexed_objects, stats->total_objects); return 0; @@ -39,9 +39,10 @@ int index_pack(git_repository *repo, int argc, char **argv) ssize_t read_bytes; char buf[512]; - repo = repo; + (void)repo; + if (argc < 2) { - fprintf(stderr, "I need a packfile\n"); + fprintf(stderr, "usage: %s index-pack \n", argv[-1]); return EXIT_FAILURE; } -- cgit v1.2.1