diff options
Diffstat (limited to 'usr.bin/cvs/root.c')
-rw-r--r-- | usr.bin/cvs/root.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.bin/cvs/root.c b/usr.bin/cvs/root.c index bfadd5d5960..b1252ed7264 100644 --- a/usr.bin/cvs/root.c +++ b/usr.bin/cvs/root.c @@ -1,4 +1,4 @@ -/* $OpenBSD: root.c,v 1.30 2006/01/25 13:31:45 xsa Exp $ */ +/* $OpenBSD: root.c,v 1.31 2006/04/05 01:38:56 ray Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org> * All rights reserved. @@ -90,8 +90,7 @@ cvsroot_parse(const char *str) } } - root = (struct cvsroot *)xmalloc(sizeof(*root)); - memset(root, 0, sizeof(*root)); + root = xcalloc(1, sizeof(*root)); root->cr_ref = 1; root->cr_method = CVS_METHOD_NONE; CVS_RSTVR(root); |