Tom Lane wrote:
> Bruce Momjian <> writes:
> > Yep, it is a bug on 8.0.X.  Are you suggesting a backpatch?  We can do
> > it.  Any objections?
> I think he's suggesting that we depend on GetFullPathName(), which seems
> a bit pointless considering we have to write the code anyway for other
> platforms.


> I didn't much like the patch as-is; we should think a little harder
> about fixing the logic properly.

I thought about it.  Here is where we get stuck:

        usr/local/../../.. has to return  ..

Yuck.  If it an absolute path like /usr, you are fine.

In my first attempt, I counted the number of ".." groups, then went up
to remove each "..", and them remove a regular directory for each "..".
And then you have this case:


Here you hit the first ".." as you are going up.  It just seemed like a
lost cause.

  Bruce Momjian                        |               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?


Reply via email to