summaryrefslogtreecommitdiff
path: root/builtin-commit-tree.c
diff options
context:
space:
mode:
authorLuiz Fernando N. Capitulino <lcapitulino@mandriva.com.br>2007-04-25 11:18:41 -0300
committerJunio C Hamano <junkio@cox.net>2007-04-25 13:45:12 -0700
commit3e0a93a5bf9fe10453599a94af8191f421ee3b16 (patch)
tree2615581612d0c64c00e146c82bfedeecd7a5040f /builtin-commit-tree.c
parent79dbbedd78ae064be6bb8a0f61fd4872222e47dd (diff)
downloadgit-3e0a93a5bf9fe10453599a94af8191f421ee3b16.tar.gz
init_buffer(): Kill buf pointer
We don't need it, it's possible to assign the block of memory to bufp Signed-off-by: Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-commit-tree.c')
-rw-r--r--builtin-commit-tree.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin-commit-tree.c b/builtin-commit-tree.c
index 4a8d8d8b67..ccbcbe30da 100644
--- a/builtin-commit-tree.c
+++ b/builtin-commit-tree.c
@@ -16,9 +16,8 @@
*/
static void init_buffer(char **bufp, unsigned int *sizep)
{
- char *buf = xmalloc(BLOCKING);
+ *bufp = xmalloc(BLOCKING);
*sizep = 0;
- *bufp = buf;
}
static void add_buffer(char **bufp, unsigned int *sizep, const char *fmt, ...)