summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authoraugustss <augustss@NetBSD.org>2001-11-19 00:37:22 +0000
committeraugustss <augustss@NetBSD.org>2001-11-19 00:37:22 +0000
commitdfbba4149c049d803f6e109e5504a3b7ace8b92a (patch)
tree98d33ffa2257990f1998497aa59b20f6e212fa2e /sys/dev
parentae27210d46756da7a7c217dce41070ea67960be7 (diff)
Injecting events into a mux that is not open is not an error.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/wscons/wsmux.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/sys/dev/wscons/wsmux.c b/sys/dev/wscons/wsmux.c
index fd6a1efe09f..a5eebcbb6fb 100644
--- a/sys/dev/wscons/wsmux.c
+++ b/sys/dev/wscons/wsmux.c
@@ -1,4 +1,4 @@
-/* $NetBSD: wsmux.c,v 1.24 2001/11/13 06:17:47 lukem Exp $ */
+/* $NetBSD: wsmux.c,v 1.25 2001/11/19 00:37:22 augustss Exp $ */
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -44,7 +44,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wsmux.c,v 1.24 2001/11/13 06:17:47 lukem Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wsmux.c,v 1.25 2001/11/19 00:37:22 augustss Exp $");
#include "wsdisplay.h"
#include "wsmux.h"
@@ -410,8 +410,11 @@ wsmux_do_ioctl(struct device *dv, u_long cmd, caddr_t data, int flag,
DPRINTF(("%s: inject\n", sc->sc_base.me_dv.dv_xname));
evar = sc->sc_base.me_evp;
- if (evar == NULL) /* XXX is this an error? */
- return (EACCES);
+ if (evar == NULL) {
+ /* No event sink, so ignore it. */
+ DPRINTF(("wsmux_do_ioctl: event ignored\n"));
+ return (0);
+ }
s = spltty();
get = evar->get;