pgsql: pg_upgrade: fix CopyFile() on Windows to fail on file existence

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: pg_upgrade: fix CopyFile() on Windows to fail on file existence
Date: 2015-11-24 22:18:35
Message-ID: E1a1Lv1-000278-BR@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

pg_upgrade: fix CopyFile() on Windows to fail on file existence

Also fix getErrorText() to return the right error string on failure.
This behavior now matches that of other operating systems.

Report by Noah Misch

Backpatch through 9.1

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/b17dbf26293e3805b5f7ab5a11a8e3f984c476ad

Modified Files
--------------
src/bin/pg_upgrade/check.c | 16 ++++++++--------
src/bin/pg_upgrade/controldata.c | 2 +-
src/bin/pg_upgrade/exec.c | 8 ++++----
src/bin/pg_upgrade/file.c | 8 ++++----
src/bin/pg_upgrade/function.c | 2 +-
src/bin/pg_upgrade/option.c | 2 +-
src/bin/pg_upgrade/pg_upgrade.c | 2 +-
src/bin/pg_upgrade/pg_upgrade.h | 2 +-
src/bin/pg_upgrade/relfilenode.c | 2 +-
src/bin/pg_upgrade/tablespace.c | 2 +-
src/bin/pg_upgrade/util.c | 9 +++------
src/bin/pg_upgrade/version.c | 4 ++--
12 files changed, 28 insertions(+), 31 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Teodor Sigaev 2015-11-25 13:35:33 pgsql: Improve pageinspect module
Previous Message Peter Eisentraut 2015-11-24 03:09:13 pgsql: doc: Some improvements on CREATE POLICY and ALTER POLICY documen