The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Chris Wright <chrisw@osdl.org>
To: Jakub Jelinek <jakub@redhat.com>
Cc: Chris Wright <chrisw@osdl.org>,
	Manfred Spraul <manfred@colorfullife.com>,
	Andrew Morton <akpm@osdl.org>,
	Ulrich Drepper <drepper@redhat.com>,
	Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] mq_open() honor leading slash
Date: Thu, 15 Apr 2004 13:02:36 -0700	[thread overview]
Message-ID: <20040415130236.I21045@build.pdx.osdl.net> (raw)
In-Reply-To: <20040415192735.GO31589@devserv.devel.redhat.com>; from jakub@redhat.com on Thu, Apr 15, 2004 at 03:27:35PM -0400

* Jakub Jelinek (jakub@redhat.com) wrote:
> On Thu, Apr 15, 2004 at 11:39:51AM -0700, Chris Wright wrote:
> > Patch below simply eats all leading slashes before passing name to
> > lookup_one_len() in mq_open() and mq_unlink().
> 
> glibc already strips the leading slash in userland.

Ah, OK.  I'm just using the kernel interfaces directly.

> If you want to do it in the kernel instead, it shouldn't IMHO be silent if it
> doesn't see a leading slash or sees more than one. I.e.
> 	error = -EINVAL;
> 	if (name[0] != '/')
> 		goto out_err;

Given it's implementation defined what happens w/out leading slash, I
see no trouble with allowing names w/out leading slashes to be looked
up as well as names with leading slash (in kernel rather than glibc).
But I don't feel strongly either way.

thanks,
-chris
-- 
Linux Security Modules     http://lsm.immunix.org     http://lsm.bkbits.net

  reply	other threads:[~2004-04-15 20:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-15 18:39 [PATCH] mq_open() honor leading slash Chris Wright
2004-04-15 19:27 ` Jakub Jelinek
2004-04-15 20:02   ` Chris Wright [this message]
2004-04-15 20:24 ` Manfred Spraul
2004-04-15 20:38   ` Chris Wright

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040415130236.I21045@build.pdx.osdl.net \
    --to=chrisw@osdl.org \
    --cc=akpm@osdl.org \
    --cc=drepper@redhat.com \
    --cc=jakub@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=manfred@colorfullife.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox