{"thread":{"id":"701","subject":"[PATCH] Performance fix for pickaxe.","startedAt":"2005-05-23T07:25:15Z","lastAt":"2005-05-23T07:25:15Z","messageCount":1,"participants":["Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"3798","messageId":"7vis1a76as.fsf@assigned-by-dhcp.cox.net","threadId":"701","inReplyTo":null,"subject":"[PATCH] Performance fix for pickaxe.","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2005-05-23T07:25:15Z","receivedAt":"2005-05-23T07:25:15Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"The pickaxe was expanding the blobs and searching in them even\nwhen it should have already known that both sides are the same.\n\nSigned-off-by: Junio C Hamano <junkio@cox.net>\n---\n\ndiffcore-pickaxe.c |    3 ++-\n1 files changed, 2 insertions(+), 1 deletion(-)\n\ndiff --git a/diffcore-pickaxe.c b/diffcore-pickaxe.c\n--- a/diffcore-pickaxe.c\n+++ b/diffcore-pickaxe.c\n@@ -44,7 +44,8 @@ void diffcore_pickaxe(const char *needle\n \t\t\tif (contains(p->one, needle, len))\n \t\t\t\tdiff_q(&outq, p);\n \t\t}\n-\t\telse if (contains(p->one, needle, len) !=\n+\t\telse if (!diff_unmodified_pair(p) &&\n+\t\t\t contains(p->one, needle, len) !=\n \t\t\t contains(p->two, needle, len))\n \t\t\tdiff_q(&outq, p);\n \t\tif (onum == outq.nr)\n------------------------------------------------\n\n"}]}