summaryrefslogtreecommitdiff
path: root/sys/dev/sbus/qec.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/sbus/qec.c')
-rw-r--r--sys/dev/sbus/qec.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/sbus/qec.c b/sys/dev/sbus/qec.c
index 5f118c0b5a3..bc699718374 100644
--- a/sys/dev/sbus/qec.c
+++ b/sys/dev/sbus/qec.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: qec.c,v 1.10 2006/06/02 20:00:56 miod Exp $ */
+/* $OpenBSD: qec.c,v 1.11 2007/09/10 19:49:31 gilles Exp $ */
/* $NetBSD: qec.c,v 1.12 2000/12/04 20:12:55 fvdl Exp $ */
/*-
@@ -192,13 +192,12 @@ qecattach(parent, self, aux)
}
/* Allocate a bus tag */
- sbt = malloc(sizeof(*sbt), M_DEVBUF, M_NOWAIT);
+ sbt = malloc(sizeof(*sbt), M_DEVBUF, M_NOWAIT|M_ZERO);
if (sbt == NULL) {
printf("%s: attach: out of memory\n", self->dv_xname);
return;
}
- bzero(sbt, sizeof *sbt);
strlcpy(sbt->name, sc->sc_dev.dv_xname, sizeof(sbt->name));
sbt->cookie = sc;
sbt->parent = sc->sc_bustag;