From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964783AbVI0B3d (ORCPT ); Mon, 26 Sep 2005 21:29:33 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S964787AbVI0B3d (ORCPT ); Mon, 26 Sep 2005 21:29:33 -0400 Received: from smtp.osdl.org ([65.172.181.4]:26008 "EHLO smtp.osdl.org") by vger.kernel.org with ESMTP id S964783AbVI0B3d (ORCPT ); Mon, 26 Sep 2005 21:29:33 -0400 Date: Mon, 26 Sep 2005 18:29:19 -0700 (PDT) From: Linus Torvalds To: Krzysztof Benedyczak cc: linux-kernel@vger.kernel.org, Michael Kerrisk , Michal Wronski Subject: Re: [PATCH] umask in POSIX message queues In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 26 Sep 2005, Krzysztof Benedyczak wrote: > > All kernels (form 2.6.6) ignore umask when creating new queues via > mq_open (when creating with open() on mqueue fs it is ok of course). > According to specification this a bug. The following trivial patch fixes > this. It should apply cleanly to any current kernel. Please apply. As far as I can tell, the VFS layer should have done this for us already, with code like ... if (!IS_POSIXACL(dir->d_inode)) mode &= ~current->fs->umask; error = vfs_create(dir->d_inode, path.dentry, mode, nd); ... in fs/namei.c (open_namei()). Which path did you come through that didn't do this? That would be the real bug, I suspect.. Linus