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_4_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/f91c4e326aa9c81223146b43b4167c29630155c4
Modified Files
--------------
contrib/pg_upgrade/check.c | 16 ++++++++--------
contrib/pg_upgrade/controldata.c | 2 +-
contrib/pg_upgrade/exec.c | 8 ++++----
contrib/pg_upgrade/file.c | 8 ++++----
contrib/pg_upgrade/function.c | 2 +-
contrib/pg_upgrade/option.c | 2 +-
contrib/pg_upgrade/pg_upgrade.c | 2 +-
contrib/pg_upgrade/pg_upgrade.h | 2 +-
contrib/pg_upgrade/relfilenode.c | 2 +-
contrib/pg_upgrade/tablespace.c | 2 +-
contrib/pg_upgrade/util.c | 9 +++------
contrib/pg_upgrade/version.c | 4 ++--
contrib/pg_upgrade/version_old_8_3.c | 14 +++++++-------
13 files changed, 35 insertions(+), 38 deletions(-)