diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-09-03 14:26:55 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-09-03 14:26:55 +0000 |
commit | 11f3d60016d0a4de4014121ff35d6d1b7d6817bf (patch) | |
tree | 268c999137bbb23843a535f6191e5b115699170f /sbin/init | |
parent | 90562873806dad0660901e9b9d25801343dd0af8 (diff) |
malloc(n * m) -> calloc(n, m); ok espie
Diffstat (limited to 'sbin/init')
-rw-r--r-- | sbin/init/init.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sbin/init/init.c b/sbin/init/init.c index 127813ac7e2..8c61f2aea0e 100644 --- a/sbin/init/init.c +++ b/sbin/init/init.c @@ -1,4 +1,4 @@ -/* $OpenBSD: init.c,v 1.39 2006/06/22 00:25:22 deraadt Exp $ */ +/* $OpenBSD: init.c,v 1.40 2007/09/03 14:26:54 deraadt Exp $ */ /* $NetBSD: init.c,v 1.22 1996/05/15 23:29:33 jtc Exp $ */ /*- @@ -43,7 +43,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)init.c 8.2 (Berkeley) 4/28/95"; #else -static char rcsid[] = "$OpenBSD: init.c,v 1.39 2006/06/22 00:25:22 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: init.c,v 1.40 2007/09/03 14:26:54 deraadt Exp $"; #endif #endif /* not lint */ @@ -824,7 +824,7 @@ char ** construct_argv(char *command) { int argc = 0; - char **argv = (char **) malloc(((strlen(command) + 1) / 2 + 1) * + char **argv = (char **) calloc((strlen(command) + 1) / 2 + 1, sizeof (char *)); static const char separators[] = " \t"; |