Re: is_absolute_path incorrect on Windows - Mailing list pgsql-hackers

From Tom Lane
Subject Re: is_absolute_path incorrect on Windows
Date
Msg-id 2369.1275402072@sss.pgh.pa.us
Whole thread Raw
In response to Re: is_absolute_path incorrect on Windows  (Bruce Momjian <bruce@momjian.us>)
Responses Re: is_absolute_path incorrect on Windows  (Giles Lean <giles.lean@pobox.com>)
List pgsql-hackers
Bruce Momjian <bruce@momjian.us> writes:
> Giles Lean wrote:
>> Names are hard, but if I understood the original post, the
>> revised function is intended to check that the directory is
>> below the current working directory.

> We check for things like ".." other places, though we could roll that
> into the macro if we wanted.  Because we are adding a new function, that
> might make sense.

Yeah.  If we were to go with Greg's suggestion of inventing a separate
is_relative_to_cwd test function, I'd expect that to insist on no ".."
while it was at it.

That seems like a fairly clean approach in the abstract, but I agree
that somebody would have to look closely at each existing usage to be
sure it works out well.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Trigger function in a multi-threaded environment behavior
Next
From: "Kevin Grittner"
Date:
Subject: Re: dividing money by money