From fa842d843d4ed336cc21ba45d2d13ff83c63b22f Mon Sep 17 00:00:00 2001 From: Rene Scharfe Date: Wed, 30 Aug 2017 19:49:41 +0200 Subject: diff: release strbuf after use in diff_summary() Signed-off-by: Rene Scharfe Signed-off-by: Junio C Hamano --- diff.c | 1 + 1 file changed, 1 insertion(+) diff --git a/diff.c b/diff.c index 3d3e553a98..4148ba6980 100644 --- a/diff.c +++ b/diff.c @@ -5314,6 +5314,7 @@ static void diff_summary(struct diff_options *opt, struct diff_filepair *p) strbuf_addf(&sb, " (%d%%)\n", similarity_index(p)); emit_diff_symbol(opt, DIFF_SYMBOL_SUMMARY, sb.buf, sb.len, 0); + strbuf_release(&sb); } show_mode_change(opt, p, !p->score); break; -- cgit v1.2.3