aboutsummaryrefslogtreecommitdiff
path: root/check-ref-format.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@osdl.org>2006-03-12 22:26:34 -0800
committerJunio C Hamano <junkio@cox.net>2006-03-12 23:02:00 -0800
commit90bd932c811f4ecd1d8cbceffdf6a69a5ca838b7 (patch)
treee216ba53a838787fa7931a23a0b335cb709aaba1 /check-ref-format.c
parentfc66d213f8b2f13b9ffd643f01de25ddc95e0972 (diff)
downloadgit-90bd932c811f4ecd1d8cbceffdf6a69a5ca838b7.tar.gz
git-90bd932c811f4ecd1d8cbceffdf6a69a5ca838b7.tar.xz
Fix up diffcore-rename scoring
The "score" calculation for diffcore-rename was totally broken. It scaled "score" as score = src_copied * MAX_SCORE / dst->size; which means that you got a 100% similarity score even if src and dest were different, if just every byte of dst was copied from src, even if source was much larger than dst (eg we had copied 85% of the bytes, but _deleted_ the remaining 15%). That's clearly bogus. We should do the score calculation relative not to the destination size, but to the max size of the two. This seems to fix it. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'check-ref-format.c')
0 files changed, 0 insertions, 0 deletions