X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=diffcore-rename.c;h=ef239012b65c901bba5eef598f62679fd288106e;hb=151602df00b8e5c5b4a8193f59a94b85f9b5aebc;hp=1de8d32502a77b641e004e9df9da3fcc188eef9c;hpb=17e6019a2ac9ad392c2e1c7fb6ce9c53d3d45acf;p=git.git diff --git a/diffcore-rename.c b/diffcore-rename.c index 1de8d3250..ef239012b 100644 --- a/diffcore-rename.c +++ b/diffcore-rename.c @@ -101,7 +101,7 @@ static int is_exact_match(struct diff_filespec *src, int contents_too) { if (src->sha1_valid && dst->sha1_valid && - !memcmp(src->sha1, dst->sha1, 20)) + !hashcmp(src->sha1, dst->sha1)) return 1; if (!contents_too) return 0; @@ -205,6 +205,7 @@ static void record_rename_pair(int dst_index, int src_index, int score) fill_filespec(two, dst->sha1, dst->mode); dp = diff_queue(NULL, one, two); + dp->renamed_pair = 1; if (!strcmp(src->path, dst->path)) dp->score = rename_src[src_index].score; else