Skip to content

Commit

Permalink
diffcore-rename.c: avoid set-but-not-used warning
Browse files Browse the repository at this point in the history
Since 9d8a5a5 (diffcore-rename: refactor "too many candidates" logic,
2011-01-06), diffcore_rename() initializes num_src but does not use it
anymore.  "-Wunused-but-set-variable" in gcc-4.6 complains about this.

Signed-off-by: Jim Meyering <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
meyering authored and gitster committed Jun 1, 2011
1 parent 2b0b64e commit 6051561
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions diffcore-rename.c
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ void diffcore_rename(struct diff_options *options)
struct diff_queue_struct outq;
struct diff_score *mx;
int i, j, rename_count, skip_unmodified = 0;
int num_create, num_src, dst_cnt;
int num_create, dst_cnt;
struct progress *progress = NULL;

if (!minimum_score)
Expand Down Expand Up @@ -554,7 +554,6 @@ void diffcore_rename(struct diff_options *options)
* files still remain as options for rename/copies!)
*/
num_create = (rename_dst_nr - rename_count);
num_src = rename_src_nr;

/* All done? */
if (!num_create)
Expand Down

0 comments on commit 6051561

Please sign in to comment.