From: Tom Lane <tgl@sss.pgh.pa.us>
To: Craig Ringer <ringerc@ringerc.id.au>
Cc: hrtlik@gmail.com
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #7590: Data corruption using pg_dump only with -Z parameter
Date: Sat, 13 Oct 2012 09:13:50 -0400
Message-ID: <11325.1350134030@sss.pgh.pa.us> (raw)
In-Reply-To: <507959C8.1010300@ringerc.id.au>
References: <E1TLafo-0003kU-99@wrigleys.postgresql.org>
<2464.1349807895@sss.pgh.pa.us>
<507959C8.1010300@ringerc.id.au>
Craig Ringer <ringerc@ringerc.id.au> writes:
> On 10/10/2012 02:38 AM, Tom Lane wrote:
>> On Windows, that doesn't seem terribly surprising: Windows will probably
>> do newline munging on the process's stdout, which will corrupt
>> compressed data since it's not plain text.
> pg_dump might want to refuse to write to stdout when in a non-plain-text
> mode on Windows if that's the case.
Actually, a look at the pg_dump code says that it does
setmode(fileno(stdout), O_BINARY);
so either my diagnosis is wrong or there's some reason why that setting
didn't take.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, ringerc@ringerc.id.au, hrtlik@gmail.com
Subject: Re: BUG #7590: Data corruption using pg_dump only with -Z parameter
In-Reply-To: <11325.1350134030@sss.pgh.pa.us>
References: <E1TLafo-0003kU-99@wrigleys.postgresql.org> <2464.1349807895@sss.pgh.pa.us> <507959C8.1010300@ringerc.id.au> <11325.1350134030@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox