lkml.org 
[lkml]   [2013]   [Aug]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/2] ipc/mq: Do not vaild queue attributes default/ceiling value If the user pass attr as NULL
Date
Kernel should not validate queue attributes default/ceiling value while
creating a mqueue, if user pass attr as NULL. Otherwise In worst case
If the validation fails then sys_mq_open returns -EINVAL/-EOVERFLOW
which will make user clueless about reason for the failure.

Signed-off-by: Sasikantha Babu <sasikanth.v19@gmail.com>
---
ipc/mqueue.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/ipc/mqueue.c b/ipc/mqueue.c
index ae1996d..04ece80 100644
--- a/ipc/mqueue.c
+++ b/ipc/mqueue.c
@@ -748,9 +748,6 @@ static struct file *do_create(struct ipc_namespace *ipc_ns, struct inode *dir,
ipc_ns->mq_msg_default);
def_attr.mq_msgsize = min(ipc_ns->mq_msgsize_max,
ipc_ns->mq_msgsize_default);
- ret = mq_attr_ok(ipc_ns, &def_attr);
- if (ret)
- return ERR_PTR(ret);
}

mode &= ~current_umask();
--
1.7.3.4


\
 
 \ /
  Last update: 2013-08-12 17:21    [W:0.036 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site