Fix two unused variable warnings in gcc 4.6
Seen with -Wunused-but-set-variable. Signed-off-by: Dan McGee <dpmcgee@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Dan McGee committed
Mar 27, 2011 at 20:32 UTC
13ee1384ef0004bd9fa6e4d2b832b49ce2e8a032
2 files changed
+1
-6
http-fetch.c
+1
-2
@@ -8,7 +8,6 @@ static const char http_fetch_usage[] = "git http-fetch "
8
9
int main(int argc, const char **argv)
10
{
11
- const char *prefix;
11
struct walker *walker;
12
int commits_on_stdin = 0;
13
int commits;
@@ -60,7 +59,7 @@ int main(int argc, const char **argv)
59
if (argv[arg])
60
str_end_url_with_slash(argv[arg], &url);
61
63
- prefix = setup_git_directory();
62
+ setup_git_directory();
63
64
git_config(git_default_config, NULL);
65
merge-recursive.c
-4
@@ -356,7 +356,6 @@ static void make_room_for_directories_of_df_conflicts(struct merge_options *o,
356
*/
357
const char *last_file = NULL;
358
int last_len = 0;
359
- struct stage_data *last_e;
359
int i;
360
361
for (i = 0; i < entries->nr; i++) {
@@ -386,7 +385,6 @@ static void make_room_for_directories_of_df_conflicts(struct merge_options *o,
385
if (S_ISREG(e->stages[2].mode) || S_ISLNK(e->stages[2].mode)) {
386
last_file = path;
387
last_len = len;
389
- last_e = e;
388
} else {
389
last_file = NULL;
390
}
@@ -961,7 +959,6 @@ static int process_renames(struct merge_options *o,
959
}
960
961
for (i = 0, j = 0; i < a_renames->nr || j < b_renames->nr;) {
964
- char *src;
962
struct string_list *renames1, *renames2Dst;
963
struct rename *ren1 = NULL, *ren2 = NULL;
964
const char *branch1, *branch2;
@@ -996,7 +993,6 @@ static int process_renames(struct merge_options *o,
993
ren2 = ren1;
994
ren1 = tmp;
995
}
999
- src = ren1->pair->one->path;
996
997
ren1->dst_entry->processed = 1;
998
ren1->src_entry->processed = 1;