From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | William ZHANG <uniware(at)zedware(dot)org>, pgsql-patches(at)postgresql(dot)org |
Subject: | Re: Bug in canonicalize_path() |
Date: | 2005-08-12 19:44:16 |
Message-ID: | 200508121944.j7CJiGR13830@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
Tom Lane wrote:
> I wrote:
> > Uh, that hardly meets the API contract that I mentioned. I think
> > we really have to throw an error if the path tries to ".." above
> > the starting point.
>
> After rereading all the callers of canonicalize_path, I've concluded
> that none of them actually depend on not having a terminating ".."
> as I thought. There is a risk factor, which is that a lot of places
> blindly trim the last component of a path --- but AFAICS, this is only
> done with paths that are known to represent the name of a program,
> so the last component wouldn't be ".." anyway.
>
> So your last version of the patch seems like the way to go. I'll
> apply it along with changing path.c to support the parent-directory
> test better.
OK, here is a version that errors out that I just applied and reversed
out when I saw your email. Feel free to use it or discard it.
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073
Attachment | Content-Type | Size |
---|---|---|
unknown_filename | text/plain | 5.8 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2005-08-12 19:47:13 | Re: PATCH to allow concurrent VACUUMs to not lock each |
Previous Message | Tom Lane | 2005-08-12 19:40:29 | Re: Bug in canonicalize_path() |