Re: Use of access(X_OK) check in pg_upgrade

Bruce Momjian <bruce@momjian.us>

From: Bruce Momjian <bruce@momjian.us>
To: Bruce Momjian <bruce@momjian.us>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2011-05-18T16:13:58Z
Lists: pgsql-hackers

Attachments

Bruce Momjian wrote:
> I broke the Win32 build members by using access(X_OK) in pg_upgrade.  I
> have a fix for this but looking at pg_upgrade's exec.c, I see for
> Win32:
> 
> 	    if ((buf.st_mode & S_IXUSR) == 0)
> 
> I am confused why Windows supports S_IXUSR but not X_OK.

I have applied the attached patch to fix this.

-- 
  Bruce Momjian  <bruce@momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + It's impossible for everything to be true. +