From 28f7581806479471093b0ec021871a4343874d13 Mon Sep 17 00:00:00 2001 From: Peter Eriksen Date: Tue, 25 Jul 2006 09:30:18 +0200 Subject: Substitute xmalloc()+memset(0) with xcalloc(). Signed-off-by: Peter Eriksen Signed-off-by: Junio C Hamano --- combine-diff.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'combine-diff.c') diff --git a/combine-diff.c b/combine-diff.c index 1bc148464..919112bba 100644 --- a/combine-diff.c +++ b/combine-diff.c @@ -639,8 +639,7 @@ static int show_patch_diff(struct combine_diff_path *elem, int num_parent, /* deleted file */ result_size = 0; elem->mode = 0; - result = xmalloc(1); - result[0] = 0; + result = xcalloc(1, 1); } if (0 <= fd) close(fd); -- cgit v1.2.1