Re: Fix for win32 stat() problems

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: Fix for win32 stat() problems
Date: 2008-04-09 18:14:46
Message-ID: 24350.1207764886@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

Magnus Hagander <magnus(at)hagander(dot)net> writes:
> + #ifndef WIN32
> if (stat(xlogpath, &stat_buf) == 0)
> + #else
> + if (pgwin32_safestat(xlogpath, &stat_buf) == 0)
> + #endif

Ick. Please do this the way we normally do things when we have to
override broken Windows syscalls, that is put something like

#define stat(...) pgwin32_stat(...)

into the win32 port header file, so the calls don't have to be
nonstandard.

regards, tom lane

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Magnus Hagander 2008-04-09 18:20:29 Re: Fix for win32 stat() problems
Previous Message Andrew Chernow 2008-04-09 17:29:48 Re: [PATCHES] libpq type system 0.9a