Browse Source

Fix a memory leak

Signed-off-by: Li Hong <leehong@pku.edu.cn>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
李鸿 17 years ago committed by Junio C Hamano
parent
commit
6ba78238a8
  1. 3
      dir.c

3
dir.c

@ -169,7 +169,10 @@ static int add_excludes_from_file_1(const char *fname, @@ -169,7 +169,10 @@ static int add_excludes_from_file_1(const char *fname,
}
buf = xmalloc(size+1);
if (read_in_full(fd, buf, size) != size)
{
free(buf);
goto err;
}
close(fd);

if (buf_p)

Loading…
Cancel
Save