summaryrefslogtreecommitdiff
path: root/sys/arch/vax/qbus
diff options
context:
space:
mode:
authorThomas Nordin <nordin@cvs.openbsd.org>2002-01-10 00:11:15 +0000
committerThomas Nordin <nordin@cvs.openbsd.org>2002-01-10 00:11:15 +0000
commit4415d12cf360370d4f92c85f6e8cf8a57f7ed1e5 (patch)
treec9acc85a2f35ca718e5ed60da3a4d80e3ff0c89f /sys/arch/vax/qbus
parent634288c6fb708ac6b61b1742cec21ebc586cf1b2 (diff)
Check result from malloc(9) when using M_NOWAIT. hugh@ ok
Diffstat (limited to 'sys/arch/vax/qbus')
-rw-r--r--sys/arch/vax/qbus/uba.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/arch/vax/qbus/uba.c b/sys/arch/vax/qbus/uba.c
index 79784d246c9..7edd1b5ea81 100644
--- a/sys/arch/vax/qbus/uba.c
+++ b/sys/arch/vax/qbus/uba.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uba.c,v 1.4 2001/11/06 19:53:17 miod Exp $ */
+/* $OpenBSD: uba.c,v 1.5 2002/01/10 00:11:14 nordin Exp $ */
/* $NetBSD: uba.c,v 1.52 2000/06/04 02:14:12 matt Exp $ */
/*
* Copyright (c) 1996 Jonathan Stone.
@@ -117,6 +117,8 @@ uba_reset_establish(void (*reset)(struct device *), struct device *dev)
struct uba_reset *ur;
ur = malloc(sizeof(struct uba_reset), M_DEVBUF, M_NOWAIT);
+ if (ur == NULL)
+ panic("uba_reset_establish");
ur->ur_dev = dev;
ur->ur_reset = reset;