summaryrefslogtreecommitdiff
path: root/sys/kern/sys_mqueue.c
diff options
context:
space:
mode:
authorrmind <rmind@NetBSD.org>2009-05-16 23:58:09 +0000
committerrmind <rmind@NetBSD.org>2009-05-16 23:58:09 +0000
commitba3fa2c82fdb3fec47460901c5e786ed765c89c0 (patch)
tree608eadd08f2a79dc9e166cb9a5b97d1d38e7cb91 /sys/kern/sys_mqueue.c
parent74b6a42ba2a6e2ded08b97a7f2b15c2f59b2a3a1 (diff)
sys_mq_open: remove broken access flag check.
Noted by Stathis Kamperis.
Diffstat (limited to 'sys/kern/sys_mqueue.c')
-rw-r--r--sys/kern/sys_mqueue.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/kern/sys_mqueue.c b/sys/kern/sys_mqueue.c
index 9fadbefea4f..cceccf386e3 100644
--- a/sys/kern/sys_mqueue.c
+++ b/sys/kern/sys_mqueue.c
@@ -1,4 +1,4 @@
-/* $NetBSD: sys_mqueue.c,v 1.16 2009/04/11 23:05:26 christos Exp $ */
+/* $NetBSD: sys_mqueue.c,v 1.17 2009/05/16 23:58:09 rmind Exp $ */
/*
* Copyright (c) 2007, 2008 Mindaugas Rasiukevicius <rmind at NetBSD org>
@@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sys_mqueue.c,v 1.16 2009/04/11 23:05:26 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_mqueue.c,v 1.17 2009/05/16 23:58:09 rmind Exp $");
#include <sys/param.h>
#include <sys/types.h>
@@ -344,10 +344,7 @@ sys_mq_open(struct lwp *l, const struct sys_mq_open_args *uap,
char *name;
int mqd, error, oflag;
- /* Check access mode flags */
oflag = SCARG(uap, oflag);
- if ((oflag & O_ACCMODE) == 0)
- return EINVAL;
/* Get the name from the user-space */
name = kmem_zalloc(MQ_NAMELEN, KM_SLEEP);