Skip to content

Commit

Permalink
Always use GIT_HASHSIG_SMART_WHITESPACE when diffing for merges
Browse files Browse the repository at this point in the history
git_merge_tree_flag_t cannot contain any GIT_DIFF_FIND_xxx flags so there's not point in checking for them
  • Loading branch information
swisspol authored and Edward Thomson committed Jan 14, 2015
1 parent 36fc549 commit b3837d4
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/merge.c
Original file line number Diff line number Diff line change
Expand Up @@ -1610,13 +1610,7 @@ static int merge_normalize_opts(
opts->metric->buffer_signature = git_diff_find_similar__hashsig_for_buf;
opts->metric->free_signature = git_diff_find_similar__hashsig_free;
opts->metric->similarity = git_diff_find_similar__calc_similarity;

if (opts->flags & GIT_DIFF_FIND_IGNORE_WHITESPACE)
opts->metric->payload = (void *)GIT_HASHSIG_IGNORE_WHITESPACE;
else if (opts->flags & GIT_DIFF_FIND_DONT_IGNORE_WHITESPACE)
opts->metric->payload = (void *)GIT_HASHSIG_NORMAL;
else
opts->metric->payload = (void *)GIT_HASHSIG_SMART_WHITESPACE;
opts->metric->payload = (void *)GIT_HASHSIG_SMART_WHITESPACE;
}

return 0;
Expand Down

0 comments on commit b3837d4

Please sign in to comment.