Re: is_absolute_path incorrect on Windows

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Giles Lean <giles(dot)lean(at)pobox(dot)com>
Cc: Greg Stark <gsstark(at)mit(dot)edu>, Magnus Hagander <magnus(at)hagander(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: is_absolute_path incorrect on Windows
Date: 2010-06-01 13:37:30
Message-ID: 201006011337.o51DbUd25914@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Giles Lean wrote:
>
> Bruce Momjian <bruce(at)momjian(dot)us> wrote:
>
> > is_relative_to_cwd()?
>
> ../../../../some/other/place/not/under/cwd
>
> 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.

> If my understanding is wrong (always possible!) and it only
> has to be on the same drive, then your name is probably better
> although it doesn't mention 'drive' ... hrm.
>
> is_on_current_drive()? (Yuck.)
> is_on_current_filesystem()? (Yuck, but at least more general.)
>
> I think we (or at least I) need some clarification from the
> original poster about what the code is checking for in detail.

I think you have to look at all the reference to is_absolute_path() in
the C code.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ None of us is going to be here forever. +

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2010-06-01 13:45:29 Re: Trigger function in a multi-threaded environment behavior
Previous Message Robert Haas 2010-06-01 13:16:13 Re: [RFC] A tackle to the leaky VIEWs for RLS