diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2007-10-01 04:03:52 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2007-10-01 04:03:52 +0000 |
commit | e616cdcc0f1277f5f457c6d8f80bd54ac6da242d (patch) | |
tree | 5e9bce6ae1a86031ec60eb724a9c31cca82e8dd4 /sys/dev/ic/malo.c | |
parent | 449a45ec6bc0733c5f8c4a7eaab63071e4eb8d27 (diff) |
More easy bzero() -> M_ZERO. Use 'p = malloc(sizeof(*p) ...'.
Diffstat (limited to 'sys/dev/ic/malo.c')
-rw-r--r-- | sys/dev/ic/malo.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/dev/ic/malo.c b/sys/dev/ic/malo.c index 6a4ce957da0..72a07f79e1f 100644 --- a/sys/dev/ic/malo.c +++ b/sys/dev/ic/malo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: malo.c,v 1.79 2007/08/28 18:34:38 deraadt Exp $ */ +/* $OpenBSD: malo.c,v 1.80 2007/10/01 04:03:51 krw Exp $ */ /* * Copyright (c) 2006 Claudio Jeker <claudio@openbsd.org> @@ -1176,12 +1176,10 @@ malo_node_alloc(struct ieee80211com *ic) { struct malo_node *wn; - wn = malloc(sizeof(struct malo_node), M_DEVBUF, M_NOWAIT); + wn = malloc(sizeof(*wn), M_DEVBUF, M_NOWAIT | M_ZERO); if (wn == NULL) return (NULL); - bzero(wn, sizeof(struct malo_node)); - return ((struct ieee80211_node *)wn); } |