diff options
author | Peter Eriksen <s022018@student.dtu.dk> | 2006-07-25 09:30:18 +0200 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-07-25 14:08:09 -0700 |
commit | 28f7581806479471093b0ec021871a4343874d13 (patch) | |
tree | 4d87706c1a09a113d1e0d887560b1b5b044cc24a /builtin-add.c | |
parent | 143c89b00348759d2768003d57e0f506d281dc61 (diff) | |
download | git-28f7581806479471093b0ec021871a4343874d13.tar.gz git-28f7581806479471093b0ec021871a4343874d13.tar.xz |
Substitute xmalloc()+memset(0) with xcalloc().
Signed-off-by: Peter Eriksen <s022018@student.dtu.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-add.c')
-rw-r--r-- | builtin-add.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin-add.c b/builtin-add.c index 2d2569817..3a73a173f 100644 --- a/builtin-add.c +++ b/builtin-add.c @@ -21,8 +21,7 @@ static void prune_directory(struct dir_struct *dir, const char **pathspec, int p for (specs = 0; pathspec[specs]; specs++) /* nothing */; - seen = xmalloc(specs); - memset(seen, 0, specs); + seen = xcalloc(specs, 1); src = dst = dir->entries; i = dir->nr; |