Re: pgsql: Properly handle Win32 paths of 'E:abc', which can be either abso

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Properly handle Win32 paths of 'E:abc', which can be either abso
Date: 2011-02-12 17:03:22
Message-ID: 5079.1297530202@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
> Properly handle Win32 paths of 'E:abc', which can be either absolute or
> relative, by creating a function path_is_relative_and_below_cwd() to
> check for specific requirements. It is unclear if this fixes a security
> problem or not but the new code is more robust.

Surely this test is backwards?

+bool
+path_is_relative_and_below_cwd(const char *path)
+{
+ if (!is_absolute_path(path))
+ return false;

regards, tom lane

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2011-02-12 21:41:35 pgsql: Refactor ALTER EXTENSION UPDATE to have cleaner multi-step seman
Previous Message Tom Lane 2011-02-12 16:54:46 Re: pgsql: DDL support for collations